Hacker News new | ask | show | jobs
by benj111 15 days ago
> neither naive code nor the absolute limit you can reach with each language

Maybe a nit pick. But this isn't a basis to say you can't compare the code. The 'average' code is going to be somewhere between your two extremes. Assuming on average, the code was written by the average programmer, you can get an insight in to what the average programmer of a programming language should expect.

Now it may be that populations of programmers favour different things (speed, memory usage, ease of implementation) but that still forms a valid comparison.

1 comments

We are talking about the benchmark game here. The code for different languages was written by different programmers. For some languages, there were multiple implementations and many iterations. In this case, the researchers used the fastest one.

Some of the implementations are extremely optimized and took a lot of effort. Some implementations are not. So you might be comparing highly optimized JavaScript code with naive, below-average TypeScript code. You cannot compare those.

It would be much better if they used the same level of optimization for each language, but they didn't. Furthermore it is called a "Game" (it used to be called a "Shoot-out") because you shouldn't take it seriously. So it shouldn't be the basis of serious research.

I'm confused because there is no Typescript on the benchmark games that I can see. So what are they even using for Typescript here?