4,901 karma · joined Sep 13, 2020 (6y ago) · 1,641 submissions
comment 4y ago · link · parent
I really like the Ars Technica model, where they have short snippets available in the public RSS feeds, but also provide feeds with full articles for paying subscribers. I don't like to leave the comfort of my reader for the discomfort of a web browser (they're all terrible).
comment 4y ago · link · parent
comment 4y ago · link · parent
Machine-code binaries aren't (they are programs), but ISA of a CPU is.
I'd plug in a requirement of Turing-completeness for the source and destination language, and at that point the "semantics-preserving" variant makes perfect sense to me. Although canonically textbooks and Wikipedia don't seem to require that, so I'm fine accepting a definition not requiring Turing-completeness, just preservation of semantics.
comment 4y ago · link · parent
That's a new one for me, but I'm from Europe. I spent my childhood on rivers and lakes, rapidly alternating between food and swimming (and other things). No cramps due to food (scarcely any at all to be honest). I've had a lot more cramps in swimming pools than in natural water, now that I think about it.
> "You should be drinking 8 glasses of water a day"
I could believe that. I used to drink ~4 glasses a day, but it made me feel like a lizard (without really realizing the cause at the time). Now I drink more than 8 and feel much better.
comment 4y ago · link · parent
I've actually found a couple channels on YT specialising in lengthy reviews/essays, which I find very good. Off the top of my head:
1. Whitelight[1] - game reviews/critiques/analyses. Particularly worthy of note are the Assassin's Creed Unity[2] (1.5h), Batman Arkham City[3] (3h 10min) and Watch Dogs[4] (1h 15min) reviews.
2. MauLer[5] - critiques of mostly Star Wars, but sometimes also other mainstream films. The ongoing series of TFA critiques has 4 parts so far (there is going to be at least 6 total), each part taking anywhere between 2 and 4 hours.
I also feel that I'm forgetting some, which I don't watch regularly, but periodically am reminded about their existence and then after a long break spend several days watching, to then forget about them again.
But the channels I listed aren't fringe. Quite the contrary, they're quite popular. I think it's also interesting that one of, if not the most popular Vsauce video is the one about the Banach-Tarski paradox[6], which is almost 30 minutes long. His other videos also show this trend, where the long-form ones seem to get more views in general.
And those are just essays/reviews/etc. There is a whole genre of podcasts on youtube dedicated to 3-4h in-depth interviews. Everybody knows a whole bunch of them, therefore I don't even need to list any examples here to support that.
So it seems that YouTube is a pretty good place for long-form in-depth exploration of whatever topic (as long as you don't say "fuck", "murder" or show a human body).
[1]: <https://www.youtube.com/c/Whitelight>
[2]: <https://www.youtube.com/watch?v=Z5dOporS8IY>
[3]: <https://www.youtube.com/watch?v=l3U1TL5yBm4>
[4]: <https://www.youtube.com/watch?v=Kk2G6zc5pKo>
comment 4y ago · link · parent
This expression matches on the effect flip() and handles it with the code on the right hand side of -> which becomes the value of the function invoking the effect. In this case the handler runs the continuation for both possible values (resume true and resume false, i.e. the function was called once, but it will return twice, with true and false substituted in the place of flip() in the place which used this effect) and returns their mean as the average.
I.e. each time calculation calls flip(), the effect handler will continue the function for both true and false and then take the mean of those two results. Comments explain that flip() should simulate a coin flip, which generally gives equal probability (1/2) to true and false. Each flip() in calculation was simulated with equal number of true and false values, so it fits the expected distribution. Each time taking the mean of those values is just an expansion of the integral calculating the expected value, as per definition of expected value.
Note that there is some recursion here. While the flip() handler is executing for the first invokation of flip(), another instance of the handler will execute for second and third invokations (inside resume true). I.e. it calculates the expected value by taking the mean of the expected values of each branch created by a flip. When a branch doesn't have any more flips inside, its expected value is taken to be the constant value that this branch returns.
comment 4y ago · link · parent
Ignoring the metaphor and taking it literally: watching nature documentaries, I don't think I've ever rooted for the antelope. I've always been on the side of the big cats (particularly leopards, snow leopards and such)[1]. And reading comments under such videos, seeing most people rooting for the antelope was always disheartening to me, knowing that, if this cat doesn't kill this or another antelope soon, it's going to die. And out of the two I always prefer the cat to survive.
[1]: Will also root for the lynx feeding on a deer, no questions asked. Lynxes are awesome. :)
comment 4y ago · link · parent
comment 4y ago · link · parent
comment 4y ago · link · parent
Did you mean to write "the most [used] form"? If so, it's unreliable. If you change your Git settings to use Torvals' email address, on GitHub it will show up as if your commits were made by his account[1].
[1]: <https://dev.to/martiliones/how-i-got-linus-torvalds-in-my-co...>
comment 4y ago · link · parent
To me it seems that the problem is not that Apple bought however much of whatever from TSMC, but rather that TSMC doesn't have competition at the moment. Hopefully that changes.
(I do think HN is a bit trigger-happy with downvotes lately. I don't often get downvoted, but sometimes people who reply to me with a different view do, and so they get grayed out and drop in the comments. I used to try to counter that, but my one vote doesn't work for very long, so I mostly gave up. But it's really annoying.)
comment 4y ago · link · parent
If you recorded Lord of the Rings, or Interstellar in portrait orientation, they would be pretty crappy films.
> the stuff I pay attention to when walking is more generally arranged vertically than horizontally.
I don't know what you mean.
Another point: your eyes are organized horizontally, not vertically. You have move horizontal vision than vertical. By filming in vertical orientation you quite simply make things more cramped, quite possible losing the space you could use to put more objects in, or just space out the objects you have in order to make things less messy.
Again, there are artistic reasons to sometimes prefer portrait over landscape, but that doesn't mean it's a good default. Making good films requires being conscious of those things, understanding that they are not arbitrary (therefore left just to which way it's more comfortable for people to hold their phones).
comment 4y ago · link · parent
comment 4y ago · link · parent
On my computer reading from /dev/zero (16.5GiB/s) is still significantly faster than piping yes (7.11GiB/s), so I'd be interested in an exploration of why that is. BPF would probably be useful here. Maybe when I find a moment, I'll write a follow-up, doing just that... unless someone else does it faster. ;)
comment 4y ago · link · parent
> This backtracking-based approach works, but it comes with a problem. The number of branches we need to test can exponentially increase with the size of the regex in certain situations, which means that testing all the branches would potentially take forever.
I think that's where it went wrong. And my comment is also subtly wrong in that it implicitly assumed this is right and proceeded from there.
The important part though is that simulating an NFA grows with the regex, while with DFA it doesn't, and you can also find it in Russ's article ("Caching the NFA to build a DFA").
The article's claim that this is what grep and AWK use is also contradicted by Russ. Claim:
> Incidentally, this is the approach used in grep and awk.
Russ:
> Awk, Tcl, GNU grep, and GNU awk build DFAs, either precomputing them or using the on-the-fly construction described in the next section.
[1]: Most sources claim that it's actually O(nm^2), where m is the number of states of NFA (which is linear to length of regex, so you can treat m as length of regex as well).