HackerTrans
TopNewTrendsCommentsPastAskShowJobs

shadedtriangle

no profile record

comments

shadedtriangle
·il y a 2 mois·discuss
I know this is naive but I wonder why the CCPA, together with the Department of Agriculture, chose not to purchase the peach canning facilities that Del Monte Foods was running. I suppose that it's more risk for the farmers in a world where canned peach sales are declining. I can't imagine it's easy to just clear cut a ton of trees though. 9 million sounds like nothing when it will take years for whatever new crop they plant to fruit.
shadedtriangle
·il y a 2 ans·discuss
Yes, the city of Seattle instituted a sweetened beverage tax in 2017 and there was a study with results published in 2023.

https://www.seattle.gov/sweetened-beverage-tax-community-adv...
shadedtriangle
·il y a 2 ans·discuss
I feel like this article is missing one of the most useful idioms of parameter packs which is when you want to accept a variety of parameter types to a non-template function. You can stuff a parameter pack into an array/vector of unions/variants which is quite useful! For example it's the way to implement std::format which is based off Python's string.format().

  using FormatArg = variant<int, float, string>;
  string FormatArgs(const char* fmt, const vector<FormatArg> &args);
  
  template <typename... Args>
  string Format(const char* fmt, Args&&... args) {
    vector<FormatArg> expanded_args = {args...};
    return FormatArgs(fmt, expanded_args);
  }

  int main() {
    cout << Format("Hello {} pi {}", "world", 3.14f);
  }
https://godbolt.org/z/v5zo99aGe
shadedtriangle
·il y a 3 ans·discuss
J, K, and L are keyboard shortcuts for "skip back 10s", "toggle pause", and "skip forward 10s". Left and right arrow keys do the same skipping. On mobile a double tap on either side of the screen again skips forward/back. A double tap with two fingers skips a chapter. Makes hopping around in a video a breeze.
shadedtriangle
·il y a 3 ans·discuss
It's because the algorithm is easy to implement and efficient in terms of compute usage to match a gesture. It's a "cheap and easy" recognizer, a $1 recognizer. The name has spawned a whole host of similarly named papers which you can see on their "impact" page https://depts.washington.edu/acelab/proj/dollar/impact.html.
shadedtriangle
·il y a 4 ans·discuss
We can see it and it’s called the Cosmic Microwave Background https://en.m.wikipedia.org/wiki/Cosmic_microwave_background. It’s not t=0.0000001 though as the time before the cosmic microwave background the universe was opaque to photons, you wouldn’t be able to see anything.