I remember liking the java sdk java source. Great small focused functions and nice use of newlines. You could tell the developers were forged in an era without syntax highlighting and large horizontal screens. Extremely scannable.
The Java standard library will forever be my baseline for “good.” Perhaps the C# beats it, but then the overall ecosystem of third-party libraries is such that it isn’t worth the slight improvements in design. Node, by comparison, is a ghetto.
Ask HN: What's the best source code you've read?
91–100 of 271 posts
Re: Ask HN: What's the best source code you've read?
#92Earlier quoted context omitted.
The book "A Deepness in the Sky" features people living on an ship whose operating system is thousands of years old. One of the main characters is considered a software archaeologist of sorts - he's an engineer, but in a sense also a historical researcher. I can't emphasize enough that this notion is only a side point in the story and not a main aspect of the plot, sadly, so I wouldn't go reading it in hopes of heari…
Interesting to note that you’re basically describing the concept of common law.
Re: Ask HN: What's the best source code you've read?
#93Earlier quoted context omitted.
The book "A Deepness in the Sky" features people living on an ship whose operating system is thousands of years old. One of the main characters is considered a software archaeologist of sorts - he's an engineer, but in a sense also a historical researcher. I can't emphasize enough that this notion is only a side point in the story and not a main aspect of the plot, sadly, so I wouldn't go reading it in hopes of heari…
> I can't emphasize enough that this notion is only a side point in the story and not a main aspect of the plot Is it sprinkled throughout the story, or a mostly uninterrupted block of text? As in: is there an easily findable chunk of the book one could read for that idea alone? If so and you could provide a few keywords or a direct quote, I’d be interested in grabbing the book to read that.
Re: Ask HN: What's the best source code you've read?
#94Bitcoin
That’s absolutely not true. Bitcoin the app is often mixing several layers of abstractions and several usage patterns together. Is it for actually keeping track of money? Is it for APIs? is it for end users, or for servers? Is it CLI or a GUI app? And it’s in C++, which is almost never readable. And of course they have their weird names for everything (all the ScriptSigs etc), and the OP script which is at the same t…
To be fair, the slow polishing of a thousand hands continues. libsecp256k1 is tested to a level few if any FOSS libraries achieve, for example.
Re: Ask HN: What's the best source code you've read?
#95Hand-written compiler for WebAssembly Text format to binary - https://raw.githubusercontent.com/stagas/wat-compiler/main/s...
Gameboy emulator implemented in C, that also runs in the browser - https://github.com/binji/binjgb
QuickJS Javascript Engine - https://github.com/bellard/quickjs
The TypeScript language and compiler - https://github.com/microsoft/TypeScript
Re: Ask HN: What's the best source code you've read?
#96I haven’t read all of it, but the Principia source code has a comprehensive units system and makes effective use of Unicode: https://github.com/mockingbirdnest/Principia/ https://github.com/mockingbirdnest/Principia/blob/master/ast... is a decent example of both: // We compute the mean rate (slope) of the mean anomaly M(t), the mean // argument of latitude u(t), and the longitude of the ascending node Ω(t). … Product…
Re: Ask HN: What's the best source code you've read?
#97bsd code is clean
minikanren
some old lisp (le lisp or eulisp I forgot)
Re: Ask HN: What's the best source code you've read?
#98Re: Ask HN: What's the best source code you've read?
#99I haven’t read all of it, but the Principia source code has a comprehensive units system and makes effective use of Unicode: https://github.com/mockingbirdnest/Principia/ https://github.com/mockingbirdnest/Principia/blob/master/ast... is a decent example of both: // We compute the mean rate (slope) of the mean anomaly M(t), the mean // argument of latitude u(t), and the longitude of the ascending node Ω(t). … Product…
C#?
Re: Ask HN: What's the best source code you've read?
#100When I was still learning to code, I spent hours and hours and hours poking around the Django source code. In particular I was fascinated by the metaprogramming used in the Model and Query objects, and I ended up learning a ton about how Python works under the hood.