skysight-inc/HackerNews huggingface dataset:
I mean a company like this can always deny you the things you've paid for by going out of business and closing the platform.

You should just assume that if you buy a digital license to something that it's never really yours
The “branch” looks like an easy cmove target. Moreover, while it might not have a branch in the func itself, you will have to have one somewhere higher in the control flow anyway.

As for loop unrolling, I bet you a loop with unrolled calls to 2 different unDRY functions will be slower (and not only because of the most certainly present extra branches to select for them)
what about early returns?
It's as old as law itself, isn't it? From the Code of Hammurabi (translation from wikipedia):

> If a merchant should give silver to a trading agent for an investment venture, and he [the trading agent] incurs a loss on his journeys, he shall return silver to the merchant in the amount of the capital sum.

Not quite applicable, but kind of? If I give silver to Sony for a movie and Sony loses the rights to that movie, I want my damn silver back.
The story of an efficient centralized system costing more than an inefficient decentralized one replays itself throughout the lives of Germans, resulting in impoverishment of the average German.

Germany is a very rich country with the poorest people in Europe. Germany has a huge amount of political and corruption problems and they are covered up well. You will be shocked by the tax rate too if you tried to earn an income. Median German households are the poorest in all of Europe. Don't just take my word for it either.
Probably the most common comment from me in code reviews is about code being prematurely DRY’d out. Fortunately, I’ve found that mentioning the Rule of Three is usually enough to correct it, and it tends to stick in the mind. Waiting that little bit longer, more often than not there’ll be no third instance of some pattern and no need to abstract it. When a pattern does emerge, it’s a clearer one. Either way it’s less work.
I guess it depends what you mean by better person. How would being a plumber or electrician make you a better person?

Given jobs in a "healthy" economic system, I don't think anyone should do anything if their only goal is to show they improved society through their work. What do we know about the nuns that would have filled mother Teresa roles if she had not displaced them?

When you are done working for income, if you have more useful skills than a crossword puzzle player they can be used in a ~volunteer role that might not otherwise be filled.
I don't know what type of ML you do, but my experience is that it is hard to pin point poor model evaluation as being the reason for poor performance in production (especially if you have an interest in protecting your ego).
It can be hard enough to figure out if you even have poor performance in production as you often don't know how well you could/should be doing.
I have recently started thinking about what part of the performance issues I have are due to poor evaluation vs under-specification. I'm not sure how I'm supposed to tease the two apart.
NFT's: Anyone can check and verify ownership.

Receipts/Credit Card statements: only people with access to the finance system and authorization to check, can verify ownership.

For some things, a common public ledger is appropriate. For everything else, there's Mastercard ..
> I'm particularly keen on Nim's UFCS

One of my favourite parts about UFCS is how it can turn C libraries that I've had to bind into nice clean looking interfaces!

esp_err_t sw_enableRx(SwSerial *self, bool State)

Becomes

proc sw_enableRx*(self: ptr SwSerial, State: bool): esp_err_t {.importc: "$1", header: "<SwSerial.h>".}

Which when called is super lovely!

var port = sw_open(params, etc)
port.enableRx(true)
Yup. But I guess that typically happens in steps. So next DRY-programmer that comes along will add a cheezeFilledCrust boolean to that make_pizza function and so on. Every time it will seem more reasonable to add another boolean, because otherwise you have to remove the make_pizza function, and there would be SO MUCH CODE DUPLICATION.

I’ve seen this again and again in the field and I wholeheartedly agree with the sentiment in the OP. IMHO different code paths should only share code if there is good reason to believe that the code will be identical forever.
> One wonders what took so long, of course.

No One doesn't.

One need only appreciate the incestuous network of corruption that controls how long these cans get kicked down the road to fathom what took so long. Unfortunately for the medical industry someone that wasn't beholden to them got into office briefly and made it happen.
No, it should not:

A couple of years ago, we started this project called Squeak, which is simply not an attempt to give the world a free Smalltalk, but an attempt to give the world a bootstrapping mechanism for something much better than Smalltalk, and when you fool around Squeak, please, please, think of it from that standpoint. -- Alan Kay
Legal repurcussions differ. IMO it comes down to: what’s the likelihood someone pursues me, and will I survive the expected cost of my defense. Nobody likes love letters anyway.

Individuals may have a lower risk, but the cost is high if someone decides to come after you. Large corporations can take the legal costs far more easily.
Speaking about bugs, can you spot how he introduced a bug when going DRY? :)

In case it gets fixed: https://i.imgur.com/ZR2XKA7.png
The one and only important programming principle: use your brain.

Not every problem is the same and not every pattern could be used to solve every problem.
Adam was very effective when it got introduced so it was widely adopted. Since then only models that work well with Adam have made it from the idea stage to actually working. I think there's reason to believe we have over fit our model architectures to our loss functions and optimizers.
I like this idea. I thought of something like this a few years ago. A search on "sql injection ast" will show that others have considered this also.

One thing I thought of just now was the unlimited power of the database connection. When a programmer sets up a connection, it is usually for fairly simple things. And then injection happens and the connection happily processes that as well.

Perhaps it would be nice to allow the programmer to define the limited scope when opening the connection. A parameter could be added to specify a list of tables and the expected operations. So the programmer could say that the connection is going to access PRODUCTS and the only expected operation will be SELECT.

Closing the connection could also be modified to return the set of tables accessed during the connection along with the operations observed. Another thing that could be returned is a set of AST's detected with the AST in string form. These AST's could then be incorporated into the source code and also passed to the database when the connection is opened.

The database could then reject SQL that attempts to access tables outside of the specified set of allowed tables and operations. Likewise, unexpected queries could be failed.

The beauty of this is that the management of the whitelisted items is in the domain and control of the programmer. Not specifying whitelisted items is possible still and gives the status quo if that is what is wanted. It also empowers and rewards the programmer would really, really does not want to be responsible if things go crazy.
The logarithmic nature of the CO2 greenhouse effect
20 x 4 = 4 x 20 by commutativity. But the name of the number 80 is also basically 4 x 20. I guess the English equivalent would be something like ‘what is one thousand times one hundred?’ ‘One hundred thousand because multiplication is commutative’ but that is incredibly unfunny. I guess in English you think of one hundred thousand as being decomposed into a few numbers but maybe in French you just think of quatre-vingts as a single concept and will do a double-take when hearing the reason for the answer before noticing that the name of the number can be decomposed into quatre and vingt. Obviously if the joke was ever funny before it isn’t now.
For an excellent code base to see DRY in action, look at tinygrad: https://github.com/geohot/tinygrad

I believe it has a potential to be a great alternative to pytorch.

I love watching GeoHot's Twitch streams as he goes to the extreme to simplify the codebase, and the end result is amazing.
> otherwise intelligent people

[citation needed]
"I figured I'd kick off my new blog with the most click baity thing I could think of."

Then write: "Why i prefer tabs over spaces!" let the flamewars begin
I am working in a code base right now that was literally ruined because of #3. It's full of extremely difficult to follow and test higher order functions that are completely unnecessary. A feature request did come for a "half/half" pizza and we're spending our days trying to disentangle the higher order functions.

The developer who wrote this thought himself the programmer genius and wanted to make a pattern out of everything. He did not accept criticism because "DRY is a holy principle".

And that is why a post like this is important. Because next time I have someone like him in my team I can point him to this post. Argument by Authority may be a fallacy, but it is significantly more persuasive than other arguments.

And yes, you can respond to this with "why did you hire this guy in the first place, or why did you not fire him?". Well I do not make all the decisions. Not every teammate is perfect. Such is reality. Particularly in such a young industry as software development which (compared to, say, electrical engineering) is still searching a common understanding of ubiquitous best practises.
> Excel is ubiquitous in almost every workplaces

Only in workplaces which use Windows. But granted, that's the large majority of them.

> so I can use the same workflows and templates

LibreOffice Calc opens Excel files well enough.

> and don’t have to raise a request to install some new app

It's not "some" new app. It has an estimated 200 Million users worldwide, and is probably the most popular FOSS application after browsers.
Looking myself for all month the prices seem to range from 60-120€ between Paris and Munich by train. Besides, wouldn't one expect the prices to eventually drop as the service is improved and sped up?
Most schools and universities aim their curriculum at getting jobs in industry. It's been a long time since we could rely on the university system to guide students toward genius or virtue and away from money making rabbit holes.
Capitalism in a nutshell
Well, those old storage heaters were pretty much that. And they went away for a reason

Doesn't mean the idea can't be implemented better, of course.

In fact I do think there's a lot of low-hanging fruit that remains to be explored in energy production.
Caveat:

> on the same hardware
Nuclear turn green as EU parliament approves new taxonomy
Boris Johnson has agreed to resign
Boris Johnson to resign as UK Conservative party leader
IronmanJS – JavaScript Without Bloat
The hn-friends extension allows very basic user tagging if you're willing to put up with the very clunky UX to add a tag - but it's not like I use it that often and tagging is a one-off cost which IMO pays itself back via not engaging with content where past evidence suggests I'm unlikely to find "valuable discussion".

https://chrome.google.com/webstore/detail/hn-friends/ffgfcbf...

Just remembered that the HN Comments Owl extension in fact adds a mute user link to posts along with letting you highlight new comments since you last read a story and/or collapse comment threads you've seen - although that bit is a touch flaky, especially with multi-page stories, and if you comment without doing so in a new tab.

https://chrome.google.com/webstore/detail/hn-comments-owl/kp...
> standing at the mean minimizes the average squared distance

This is true, but I find it more intuitive to think about the signed distance: if you define signed_dist(x, y) = x - y, then the mean is the value that makes the average signed distance closest to 0. Of course in reality distance is unsigned – if you walk 1m left then 1m right, you've walked 1m + 1m = 2m, not 1m + -1m = 0m, so the signed distance is not appropriate.

Here is a practical example where the aim is to get the average signed difference to be closest to 0: You want to count a large number of nails by weighing them. To do that, you need to know the weight of a single nail. But the nails have slightly different weights, so you need to pick some representative value. Question: Should you pick the mean or the median? Answer: You should pick the mean, because when you weigh all the nails together the differences will cancel out.

So the rule is:

- To minimise the average value of the absolute difference, pick the median.

- To minimise the absolute value of the average difference, pick the mean.
It's still a service branch of the department of air force.
I don't wait in lines to spend my money, never, for any product.

If the bagel shop was mine however, I would have no problem making people wait as long as they were willing to tolerate; it's good marketing, and means I wouldn't have to employ as many people.
I have stopped dismissing anyone's ideas as features or won't work. I haven't had a big exit but have gone through many failures and very few tiny exits.

A feature Startup would have been something I used to call a "button" or a "switch" someone can turn on (build quickly) by another incumbent. So, I was skeptical of anything built on top of other Startups APIs -- Twitter, Facebook, or even Stripe (even though lots are surviving on the last one).

Whatever term someone labels your Startup, do a sanity check for yourself by calculating the addressable market[1], which is a simple multiplication of how many users you could get by how much money you could make per user.

Once comfortable with that, see how big this can get in the next few years. Most successful Startups start pretty small and uncanny.

But then, nothing is certain, even with the best mathematical formulas, market forces, or money. I have been part of enormous and grander ideas, massive money, and brilliant execution by the best teams and still failed. I have also missed quite a few "small ideas" that didn't seem so but then went on to grow big and succeed.

1. https://visible.vc/blog/modeling-total-addressable-market/
The stagnation is real bad. They don’t develop stuff anymore. They pay companies absurd amounts to actually do the innovation. The Military Industrial complex has sort of given itself a case of gout or diabetes… the companies grew by delivering what the military wanted, then gradually it became “your so good at giving us what we want, we’ll just let you sort it all out, just make sure it can do XYZ” … and thus the disconnect grows with the users now mostly cut out of the design loop except for limited feedback towards the end of “product development”. Which is how we get things like the F22 and the Bradley… they fulfil a design brief and channeled millions of government dollars around the country making lots of people happy… except the people that had to make use of them for their job of defending the country…

They contract out satellite designs to firms that developed standard busses based of mil spec rating commercial innovations and then spent decades launching them at whatever cost they got charged by a duopoly of commercial vendors so incestuously linked that they were legally required to merge as the simplest outcome of suing each other for stealing secrets from the other one. It really did need this sort of shakeup. And unfortunately the Cyber domain does too, but that’s in even worse shape since it’s spread across everything and has a weird estranged relationship with the “black ops cyber” (both offensive and defensive) world of stuff going on at the NSA that seems to have permanently limited the scope of Cyber into a whole weird thing.
No one who lived then and wrote anything about Jesus, including the (unknown) authors of the Gospels, ever claimed to have met Him.

We can be confident Paul existed, or anyway somebody we know of as Paul, who wrote his Letters. Likewise Homer, the Iliad. Tacitus, Pliny, Horace, Plato, Euripides. But there is nothing traceable to any Jesus. You certainly can choose to believe He existed, but objectively, the evidence is too thin to support it.

Funny thing about Noah's flood. The water is all still there. We call it the sea. Sea level rose 120 meters in the past 20,000 years, up until 8000 years ago. Many millions of square miles of what was rich river bottom land is now sea floor. People whose family had lived there for tens of thousands of years had to keep moving inland (where other people already lived!) as the sea swallowed their ancestral homes. For 12000 years. It must have made an impression.
> In this meaning of optimization, "premature optimization" is a bogus concept.

The idea is that you can end up optimizing before you know the entire use-case, because software engineering isn't like building bridges or skyscrapers.

I'm a performance geek, but I love code I can easily change rather than code that is fast until some customers have touched it. Mostly out of experience with PMs with selection bias on who they get feedback from ("faster horses" or "wires we can hook phones to").

The first thing to optimize is how fast you can solve a new problem that you didn't think about - or as my guru said "the biggest performance improvement is when code goes from not working to working properly".

The other problem with highly optimized code is that it is often checked-in after all the optimizations, so the evolution of thinking is lost entirely. I'd love to see a working bit + 25 commits to optimize it rather than 1 squashed commit.

Optimized code that works usually doesn't suffer from this commentary so the biggest opponents I have with this are the most skilled people who write code with barely any bugs - I don't bother fighting them much, but the "fun" people with work understand my point even if they write great code first time around.

These two are mostly why I talk to people about not prematurely optimizing things, because I end up "fixing" code written by 15 or more people which has performance issues after integration (or on first contact with customer).
Having some ASCII nonsense instead of standard controls is a bad idea.
But lying to the court is, so any related testimony would be illegal, making the scheme as a whole illegal.
I used Spacevim for a few months. But ditched it and Prelude for Emacs for the same reason. These things download huge source trees of config files that are painful to change, import huge amounts of extensions that will have all sorts of broken interactions, and the documentation leaves much to be desired when trying to solve these internal issues.

In the end I settled for vanilla emacs, where I gradually build up a configuration. Once a week I pick something that's been annoying me in the past week and do the configuration for that by hand. This way I avoid bloat and it keeps things pretty sane in terms of configuration complexity. Also I get plenty of time to learn all the shortcuts in my setup as opposed to having a confusing mess of 30 extensions to learn all at once.
Compared to Almere it's great... but there are many options besides Amsterdam that don't come with all the drawbacks, and cheaper to boot, especially if you have kids.

If you're single and like nightlife then I can see the draw, but otherwise it no longer is for me. But it's fine, I live 20 minutes away (Baarn) and have the advantages when I need them without the disadvantages.
Let's optimise for "years of programmers life spent worrying about it".
> Is it brand new?

No, it's 5 years old or so.

> Can you link to the relevant documentation?

https://developer.nvidia.com/blog/cuda-dynamic-parallelism-a...

> and doesn’t overall affect perf by much

Oh, but it very easily does. Slow I/O to the device, no parallelization of I/O and compute, etc - are all extremely easy pitfalls to walk into.
Erasure’s Wonderland album helps me get down to some deep deep work.
Yea shouldn't be sold at all. How there isn't a broad movement to get the money back is beyond me.
infinite money glitch irl?
I have reached similar conclusion. DRY projects tend to snowball over the years into mess where every minor change is insanely difficult, breaks everything and code is hard to read, bugs are difficult to solve, diffs are difficult.

WET code (opposite of DRY code, often starts as copy pasted) has more code, more typing, but the diffs are simple, bugs are simple (often you simply forgot to copy piece of code into 7 different places which is easy to solve). After many iterations, what started as very similar "classes" is now completely different.

One look at WET class and you know what it does, you change one line and you're done, maybe you need to copy it to 2-3 other files, maybe you don't. In comparison, you'll stare at DRY class for 2 hours and realize you need to refactor absolutely everything, it will break half of the codebase and diffs are insanely complicated.

I've recently wrote 2 similar projects, one wet one dry and wet one is simpler, easier to maintain, and more enjoyable to work on. Dry is root of all evil.
There is even an xkcd for this https://xkcd.com/519/

On the other hand, the homework i hated the most was writing essays for english class. To this day i still kind of hate that sort of thing. On the other hand, that type of writing is very similar to the type of writing they ask you to do in "peer reviews" during performance evaluations. Who knows, maybe if i was better at it, it would help my career.
Traditional vaccines are either weaker versions of the same virus created through "breeding" in animals or other manipulations OR they are replication deficient viruses, that means they can only replicated in specialized lab cells, but not in our real, normal cells.

Nanoparticle vaccines are less traditional in the sense that they do not contain a virus at all, but just particles that have the virus signature, to trick your immune system into building protection against the real virus, that has the same signature.

mrna and vector vaccines are even less traditional: They literally infect your existing, healthy cells and turn them into factories for nanoparticles. Eventually those cells are killed. The amount of particles produced for those vaccines is indeterminate, potentially leading to heavier side effects ("reactions") and the death of the infected cells itself is also not healthy.
ByteByteGo – Newsletter covering topics and trends in large-scale system design
The employee clicked on a link asking them to install a security certificate and completed the install?
Boris Johnson to resign as Conservative leader
You are powerless to accomplish anything in an adverserial situation unless you can mobilize men with weapons to do your bidding. These days it is the court systems that authorize and compel the restoration of your property with the threat of depravation of liberty or purchasing power of the defendant.
Amsterdam seems to have gotten better thanks to the pandemic. I go there on a regular basis to visit relatives with kids so I mostly visit parks and playgrounds and the drastic reduction of "bachelor party" type of tourists (coming for alcohol, drugs and prostitutes) has made the city a lot more pleasant to wander around.

Residents seem to have come to the same realization as it looks like they are going to outlaw selling drugs to tourists and move the red light district out of the city.

That being said, as long as there is still the museum/culture tourism and the many wealthy expatriates coming for the quality of life, I do not see the prices dropping back enough to make a difference for regular/local people.
Verifying ownership is kinda useless when the distributor no longer distributes, though.

You can prove you own a copy. Congrats. So can everyone else with a receipt. However, that doesn't somehow coerce Sony into continuing to provide access.
"When to use tabs, and when to use spaces."