Recent submissions

Comment · 3 years ago
When buying Merino please inform yourself about mulesing beforehand. Those sheep got bred so they have wrinkly skin, so more surface for wool growth. They suffer and likely die when not taken care of: the wool around the buttocks get encrusted in feces and urine, and the parts get often infested. Instead of breeding further sheep that are vulnerable to this, many farmers, for example most in Australia, cut off skin, so the scarred tissue won't grow wool. Google some images and decide if you want to support such practices. If you can't live without Merino wool, check up your sources, as there are less violent methods. But in the long run it would be better if those sheep weren't further bred.
Comment · 4 years ago
Comment · 4 years ago
Here it is: https://www.youtube.com/watch?v=_Jk26iKx5GU

If you eat meat, eggs, drink milk, you are supporting the things shown in the video.

Comment · 4 years ago
Too bad I have to adjust my business cards for ꙮ.world
Comment · 5 years ago

    (a -> b) -> T a -> T b
  T (a -> b) -> T a -> T b
  (a -> T b) -> T a -> T b
Comment · 5 years ago
It's part of the tokenizer. t contains data in the format of [char 0][char 1][base 64 encoded token id …], whereas the id is as long as the entry is smaller than 'b'. So it's ('++', `#m`), ('--', `%am`), ('*@', 'R<^1c'), and so on. '@' is used as a wildcard. As you can see this part parses operators.
Comment · 6 years ago
Instead of the gawk manual, I recommend the OpenBSD manpage: https://man.openbsd.org/awk.1 It's concise and well written (as most OpenBSD manpages), so you can learn AWK even in less than 2 hours. Of course it handles only AWK, not the gawk extensions.
Comment · 6 years ago
CSV to TSV via robust program, use AWK, and convert back if needed. Then you only have to remember the \\t\n\r escapes, not the whole quoting shenanigans.
Comment · 6 years ago
Comment · 6 years ago
Perfect! Thank you.
Comment · 6 years ago
Still hoping for someone to design a font for J with ligatures so it can match APL's beauty for reading without making it more difficult to type, i.e. automatically rendering /: as ⍋, |: as ⍉, |. as ⌽, etc.
Comment · 6 years ago
Comment · 6 years ago
Side note: The vel+pos example is a common one in ECS. It also often follow that you should put them in one type in the real world. However, nowadays thanks to SIMD instructions, it is probably faster to have them separate, as you don't have to unpack/align the various fields:

  // p={(x0,y0),(x1,y1),...} and v={(vx0,vy0),(vx1,vy1),...}
  for(int j=0;j<2*SIZE;j++)p[j]+=v[j];
vs.

  // pv={(x0,y0,vx0,vy0),(x1,y1,vx1,vy1),...}
  for(int j=0;j<4*SIZE;j+=4)
    pv[i+0]+=pv[i+2],pv[i+1]+=pv[i+3];
Comment · 6 years ago

  LABEL = sys._getframe().f_lineno
  print(1)
  j(LABEL)

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton