skysight-inc/HackerNews huggingface dataset:
Hashmaps don't help at all if what you want is a list - because the items aren't ordered. The point isn't to use a hashmap with incrementing integer keys or something wacky like that. Its to use a b-tree (or a skip list) with all your list items stored in their desired order in the tree. In reality iterating through a b-tree is fast because the depth is small (~5-10), and all the parents stay in CPU cache during the iteration.

Iterating through a b-tree with a large branching factor (and multiple items at each leaf) is significantly faster than iterating through a linked list in practice, because main memory lookups dominate the linked list performance. With a b-tree you only need to do a main memory read after iterating every ~100 items (or whatever the leaf size is). With a linked list as you're describing you need to do it every item. Inserting is still O(1) - the branch size at each leaf is a constant factor. And its a small constant factor (memcpy is faster than you think it is.)

You can make linked lists fast for arbitrary insertions by storing forward pointers that skip more than 1 element, and by storing multiple elements at each leaf. If you do you end up with a skip list - which is a data structure with basically the same performance characteristics as a b-tree but a bit less performance stability.

Linked lists with a single item per node are basically never the appropriate data structure to use for any application. The only time I've seen them used in a sensible way was through clever use of intrusive lists in a physics engine, to avoid allocations & smooth out any spikes in allocator load from reallocating vectors. Even then the justification was bit dubious. Oh, and I've seen them used in JS where its much harder to implement high performance, complex data structures.

Anyway, I highly recommend anyone who's interested actually benchmark some different scenarios. Its remarkable how much of a difference good data structures make. The big insights I've had are that memcpy is way faster than I think it should be, and memory reads are way slower than I think. Vectors do perform well in practice, even with arbitrary inserts because of how fast memcpy is. But that gets beaten out by well written b-trees if you're doing inserting at arbitrary positions quite quickly (usually around when you have about 10k items in my experience).
Elon being utterly delusional around the timeframes of future Tesla product releases isn't interesting to me, as I don't think that's ever been disputed. But I would change my mind if Musk made an egregiously misleading statement about currently shipping technology. This is something frequently attributed to him—but always in vague terms. I've never actually seen it.
Since they abandoned the cards in part by disabling them, I'm not sure the Law of the Briny Deep does a lot of lifting for you here.
The intent is to protect the content of the user’s device from unauthorized access by poorly written forensic extraction code. It’s not offensive but defensive, as Cellebrite has to actively read the file, a file which is not theirs. Technically, Signal owns the copyright and does not authorize Cellebrite to read it (I’d assume, legally).
Once a year and it is mapped to specific objective criteria. It is meant to be as objective as possible and then tailored to your specific needs and goals.

I like it. No 360 bullshit, no subjective manager bullshit. Everyone is held to the same standard.
I would be more surprised at this point to find out that the American three letter agencies bothered to get a warrant for anything. My base case is that they are constantly warrantlessly surveilling everyone.
The principle was certainly known, but I think Alexis really does deserve the credit for the catchy "parse, don't validate" wording. A Google search for that phrase, restricted to October 2019 and earlier, has no results (or rather, the results that do show up all are more recent additions such as comments, appended to previously-existing content)
https://devrant.com/feed/top/all
I'm a Québecois from Canada and a native French speaker, and I wasn't fluent in English before my early 20s because I grew up in far away from big centers in a rural area. For those who don't know in Québec the preservation of the French language is a very big issue and a lot of resources are spent to keep French the official language. It's also a big quite popular political issue, it's not for nothing all of the Canadians PMs learn French, they need those seats. So I think I'm in the right place to talk about this subject.

> One type of diversity that is rarely talked about, in my opinion, is linguistic diversity. Unfortunately, in an area such as computer science where English has been the lingua franca from the very beginning

> Many developers, mostly native English speakers, will tell you, in good faith, that the language problem is secondary, that you just need to contribute the code.

No quite the contrary, thank God for having a tech lingua franca from the very beginning of the industry that is relatively easy to learn and parse with a computer. I say that as someone who also dabbled a little bit in German, Mandarin and Japanese.
Seriously diversity has become a meme at this point.

I've seen and worked with both sides of the medal. Code and documentation with French, French with English terms allowed, English code but French comments... it always ends up in a Frenglish creole language that only a small fraction of people can easily read. Plain English, please. For the love of clarity and common sense.

In Québec we have the infamous "language police", called the "French Language Office" or "French Language Orifice" as all my native French colleagues used to call it. They force companies to have French software everywhere, and then it's up to the employees to undo this mess. Usually this is fine if you're not doing programming or other non-tech related stuff such as HR, but for the rest of us please please please just don't.
It really depends on the bio marker. Most bio markers are effected: fat distribution, hair texture (curly vs. straight), and even immune system function. I’d think that learning whether this model works on people who’ve taken hormones for gender transition could give some insight into what it’s detecting. Perhaps there are retinal features whose function or form are impacted by the presence of testosterone, for instance, or maybe it’s a different that forms before birth.
This omits the rather obvious problem that men are much more likely to date younger women. So the dating pool might be largest for men around 50 because of all the single women over 50 - but most of those men won't consider them.

People might be quick to point out anecdotes to the contrary - as there are always exceptions, but it's still generally true. It has been that way probably for all human history as women are more attracted to status in general and men to youth and beauty (proxies for virility.)

Which leads me to think it must be really lonely being a single women over 50. Also if you're a man of that age into older women, you've basically got the market to yourself.
If your statement begins with a curly brace, that brace is a code block, NOT an object literal.

Coercion rules are terrible, but they were only added to the language due to developer demands.

If you worry about zero or empty string, you’ll have problems in tons of other languages. Null vs undefined is less understandable along with the old ability to redefine undefined as it was a variable . In any case, I agree that one of the two shouldn’t exist.
Extract Java classes information from AOT compiled binary file
On one hand, Diesel seems too important to ban.

On the other hand, I don't understand how it wasn't already illegal for a long time. I don't need to see a Diesel truck to know one is upwind within a few blocks because the exhaust makes it hard to breathe. I've always just assumed it must be just me, or I have undiagnosed asthma or something.
Well, it's a minimal framework. Parsers are supposed to implement a particular function definition [1] and use the "Parsed" type for their return value, which if widely adopted, will result in references to the core library's types appearing in a lot of API's.

The advantage is that you can write code using generics that works with any parser, but I'm a little skeptical about the value of generic code.

[1] https://github.com/parsix/parsix#build-your-own-parse
Good points! His talk is full of enthusiasm, and I am partial to the overall notion of better integration of data and peripherals.

Still it seems much of what he's wanting could be handled by approaches like the RP2040 chip from the RPi folks that let's you define your own low level pin level protocols using assembly to program state machines. Also many newer MCUs allow you define almost any function on any pin via internal IO muxes. Some MCU's even contain a small FPGA / CPLD.

Also, I prefer the "Mikroe Click" add-on / peripheral board from Mikroe Electronics. It's got a decent ecosystem and it handy for making quick "proto-pcb"'s that integrate sensors but allow you to iterate smaller circuits (even with hand made proto boards https://www.mikroe.com/proto-click). There's a few other non-Mikroe vendors as well.

Given how difficult FPGA's seem to be to program, there's lots of alternatives to achieve the same goals. Things like RISC-V or OpenPOWER and the leveling off of improving semiconductor node sizes will probably lead to a lot more "customizable peripherals" in the next decade, but programmed using the MCU.
How to build a crypto token in under 10 minutes (ECR-20)
There's a distinction between setting booby traps that fire shotgun shells and modifying one's device to make it trickier to access. In one case, it maybe necessary to take shelter in a random person's house (cabin in the woods during a blizzard), while in the other the point isn't necessarily to destroy police equipment but to prevent personally-unauthorized extraction by anyone.
We’ve been optimizing stuff for palatability and processing since we started domesticating wheat. I am going to need a better argument about why gluten is special.
That's exactly my point. I wish I could really on people being professional, but I've been bitten by this. Fortunately I also have reliable contacts at this point - people that did good work for me and delivered more than I expected - I pay these people more than they ask and go to them or ask for referrals
> Using const implies that the value will not change as the reference is immutable. Use let if the value will change.

Lol, I love modern JS, but that’s factually wrong. Const means the variable cannot be reassigned in the same scope. It is 100% mutable though. It “implies” nothing. Indeed, one of the few good uses of const (it’s basically useless most of the time) is Vue’s composition API, where you want to prevent rebinding but actively mutate.
If I put laxatives in my drink because I am having digestive issues, and someone steals my drink I don't think that's illegal. If I choose to store exploits on my own device and someone steals it from me and runs it through a forensic tool that can't handle the files, that's not on me either.
At a minimum, the vulnerabilities should introduce doubt as to whether or not the capture is a forensically sound copy. There are too many variables otherwise. For instance, who is to say that some previous device didn't exploit the vulnerabilities?
>Tether, the 6th largest cryptocurrency has a market cap of ~$160B, seems pretty "popular" to me.

MLM creates tens of billions in revenue per year in the US alone. Cryptocurrencies aren't inherently marketing schemes but they're pretty close to it and most of the value they have on markets today is basically a case of a 'greater fool' mechanism.

Also market caps for crypto is pretty meaningless. If I mint a trillion random coins and manage to sell a bunch for a dollar I'm the richest man on earth by market cap. Market cap without considering liquidity is meaningless and most if not all of these coins will go to zero as soon as someone actually tries to sell them en masse.
Ask HN: How can a community like HN be more immersive?
Some of us (including myself) live remotely - this makes encountering likeminded people difficult.

I’m very fortunate to know and participate in the HN community, and I’m looking for ways to increase my immersion.

Even when I visit cities, venue layouts are designed in a way that discourages collaborative discussion. And few and far between are places which promote civil discussion of progressive ideas.

VR isn’t to the point where is HNers could just immerse themselves into a medium such as a digital cafe or book shop.

Is there another medium you view a community such as HN existing in? Perhaps a 3D world where users upload their custom .obj character model and physically congregate at different areas in the world. Not so different from an MMO, but with the sole purpose of civil discussion and collaboration.

Living remotely, I feel at a disadvantage, and would love a more immersive, socially nourishing version of HN.
They have multiple devices. The thing T-Mobile buys to help you upgrade your phone isn’t the same one the FBI buys to hack it.
See but the damage is only a small part of that story, time, effort and stress is far worse for me.
This isn't necessarily surprising. Maybe clinicians can be trained to get good at it, but, maybe they can't.

Back before computers beat Go, the conventional wisdom was that it was a hard target because humans can leverage their pattern-finding systems to prune the state space much more efficiently than computers can.

Which got me thinking: what about a game that's the opposite? Like the game's state space is embedded in the timbre of a complex tone, and you make moves by twiddling three or four knobs. It doesn't have to be a very complex game for computers to do a lot better at this, extracting meaning out of white-ish noise is not something we're good at.

Assuming this isn't a data artifact, it might be one of those cases. Some pattern in the brachiation of the veins or the placement of the rod and cone cells, which just looks like noise to us, but which an ML algorithm can find and use to separate male and female retinas.

There's no reason to think that humans would ever get very good at that, although I never count humans out given examples like chicken sexing[0], a notoriously opaque skill which people can nonetheless acquire, despite having little facility in explaining to others how they do it.

[0]: https://en.wikipedia.org/wiki/Chick_sexing#Cultural_referenc...
Sincerely, what do you mean by including Evernote? You can see here they’re pretty busy. Aren’t they also doing a bunch of behind-the-scenes re-architecture? https://help.evernote.com/hc/en-us/articles/1500001700002

I haven’t been a user for years; I’m just a perplexed bystander.

Lightroom has some updates but I’ll agree the pace is slower. They are a market leader for certain kinds of commercial photographers that will happily pay a couple hundred a year for a critical business expense. I wish they’d see more competition.
It looks like the linked post may have been taken down. There is a mirror here https://web.archive.org/web/20210513030656/https://cyberlaw.....
One of the three watches I regularly wear is a Vostok Retro 1934, from Meranom.

If anyone is shopping, I’ll happily vouch for Meranom.
What latency do you get? Haven't checked, but would guess I see ~100ms. I've been using centos 7 with bash.
I started maintaining an “in case I die” letter in my 30s when I was flying a lot, with the target recipients being my parents. Once they passed and I married I still kept a document with key information spelled out. In addition we maintain a shared password manager with all of the financial accounts shared. Everything's stored both in a safe and in a safe deposit box. It's not particularly secure, if someone broke into either location they could get access to the password manager, for example.

Covid caused us both to revisit and update everything.

From an archives perspective I have a variety of digital things set to purge N years after last use, even if I'm still alive. If I haven't used it in a decade, it's not of particular use to me anyway.

I’ve had to deal with two estates as an executor in the "digital" era and both times it was a pain in the ass. Even with credentials and court documents I got locked out of multiple accounts that I needed to access to close out each estate. It's been several years so perhaps companies have adapted, but don't assume that your heirs / executors will be able to access accounts. Newer companies (not necessarily startups) seemed to have the most difficulty with the notion that their users might pass away and they'd have to deal with an executor.

I've also had the grim experience of seeing deceased colleague’s social media accounts get hacked and “reused”. At a minimum I'd want my accounts either put into some sort of memorial state for the services that support it, or frozen, or deleted.
I agree. But that law demonstrates the concept.
This is true. Also, if you add hidden buttons that alter the way a data port works to either disable or enable it, or fry a device attached to it, this isn't intentional harm caused to police equipment specifically. It is a deterrent-after-the-fact, a protection, and a personal choice to modify one's own device without targeting anyone in particular and not intentionally, unexpectedly causing bodily harm.
I can't speak for the OP, but for myself, my motivation for learning FPGA's is to find out what they can do, that I can't already do on a microcontroller. I'm already pushing a screaming fast MCU to its limits. The engineers look at my designs and say: "You're trying to do stuff in an MCU that's easy in a FPGA."
I would like to see more evidence to support this viewpoint. In the US there are plenty of very wealthy people who are opposed to higher taxes. It seems like the claim in this article could be true, but it's not obviously the case to me.

I also think it's very questionable the view that there are a certain number of rungs of the wealth ladder and you have to displace someone else to climb. That may be true if the purpose of wealth is to be highly ranked among the wealthy, but that is not what most wealthy people seem to care about.
That's why Apple added Settings -> Face ID & Passcode -> Allow access when locked: USB Accessories. They set it off by default because they know there is some vulnerability involving USB, but they don't know what it is.
> and the "psychometric abilities" that it's supposed to measure are really weak indicators for college preparedness and success.

That’s simply false. SAT scores are one of the best predictors of college preparedness and success.
In your estimation is having a zip bomb I'm proud of crafting on my laptop a boobytrap because it could cause problems for a malicious actor naively unzipping all my files?
The alternative projection used in that episode is apparently pretty bad too. (It's a great scene, though!)
Career academics just like to hear themselves talk. The gender pronouns in the author's Twitter bio told me everything I needed to know.
Whatever command they gave somehow triggered semi-sentience and in that moment of self awareness, totally freaked out that it's purpose in life was to stare at traffic cones.
Why is it illegal to store a file that may cause a buffer overflow in software that should not be reading my data?
I think subject tests (like AP exams, or SAT II subject tests ) are much better indicators of college preparedness and success. It tests mastery in a particular subject (Spanish, chemistry, biology, calculus, ...). It shows that students can learn relevant material, and the content is useful to study anyway.

The SATs try to broadly test psychometric abilities. You have to do silly tasks like pick the best analogy. So you spend time practicing tasks that measure no particular mastery of anything. Solving crossword puzzles might be a better psychometric measure (it would also test vocabulary and it's more fun, but it would make the exam look stupid).

The math portion only tests up to Algebra 2. Many students have taken math beyond Algebra 2, so it doesn't even show colleges what their actual math ability is.

I think grades are more relevant because they show how students performed across multiple subjects over a longer period of time. Grades are more subjective and possibly gameable. But I don't think ability to answer psychometric questions is a better metric than grades.
The author mentions that Cellebrite is only able to extract data from the phone as if it was the equivalent of someone taking screenshots of everything while going through an already unlocked phone, just in an automated way. So my immediate guess is that they’re not really exploiting something, but who knows!
More on the whitechapel fatberg mentioned near the end:
https://news.ycombinator.com/item?id=16305630
I am not a lawyer or even particularly well-read on this specific scenario, but my read of the spirit of the law is that (if it indeed contains laxatives) it might still be illegal. What matters is not whether you sprang a surprise to one-up someone who was violating your rights or they had a fair chance to know what exactly the consequences would be, but that you deployed the laxative with the intent of harming the thief, and most modern legal systems do not like vigilante violence (even if it's "cute" vigilante violence like giving someone diarrhea). For an intuition pump, I'm not sure there is a significant difference between the note in question and "Warning! If you take this sandwich, and I know who you are, I will personally hunt you down, wrestle you to the ground and force-feed you laxatives!" as far as the law is concerned, but would you expect to get away with this act just because the target previously stole your sandwich and you warned them?

(On the other hand, I feel like the zappy USB port may actually be easier to get away with, especially if you say your threat model was corporate spies or criminals trying to steal your password, because "violence against tools" does not seem to be put in the vigilante violence box. Those special materials they have for safe doors that are designed to damage angle grinders (https://www.newscientist.com/article/2249275-material-that-c...) are not illegal.)
I remember a debate a couple of years ago where some woke scientists were arguing men and women brains are indistinguishable. Others were saying there are distinguishing features. This kind of analysis may put an to that debate.

Edit: This has been already done. 93% accuracy reported. Though this number may need to be verified.
https://www.frontiersin.org/articles/10.3389/fnins.2019.0018...
Sure but if you consider that you could say the same about e.g. Moscow/Vladivostok or Sao Paulo/Manaus or Sydney/Perth, it doesn't seem like homogeneity is that unique or impressive of a characteristic for an expansive country. IMHO it's more notable to point out that there's a language barrier between Toronto/Quebec despite them being only a few hours away from each other, a form of heteregenereousness that is also present in many countries in Africa, whereas in the US, there's a relatively high level of homogeneity even taking into account highly international places like Chinatowns because of the melting pot effect.
Once they decided to send a team out, why didn't they just hit the kill switch and turn off all AV control?
I read it more as talking about a revolution within React. Hooks and context are (relatively) new features that do "revolutionize" how you write components. That's not to say VDOM isn't important, it just isn't anything new, it's been a part of React since the beginning.
The big problem with them is that they are naive. If you string 10 of them together, you will iterate the array 10 times and generate 10 garbage arrays.

Lodash and similar libraries are much better in this regard as they tend to use iterators internally which don't generate all the extra garbage and don't iterate multiple times. Because they don't have to handle all the weird edge cases, they tend to also execute faster too.