Live data from Hacker News

Ask HN: What's the best source code you've read?

news.ycombinator.com

111–120 of 271 posts

Re: Ask HN: What's the best source code you've read?

#111

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.

Yes! A fellow square! It's almost always a pleasant surprise to dig in and see how parts of java are actually implemented.

Re: Ask HN: What's the best source code you've read?

#112
post #102

I have a soft spot for Musl libc just for how clear it is considering it's one of the most widely used libraries in containers and has to perform well in the real world. https://musl.libc.org/

This is the first thing that came to my mind as well.

I've said on here before, it takes real talent to write code which is this legible while still being small and efficient.

Re: Ask HN: What's the best source code you've read?

#117
post #37

The early Go standard library (before it was hyper-optimized.)

I can't understate how valuable it is for a new language's stdlib to be so well written and therefore an excellent reference for style, design, performance, documentation etc. in your own code. Every time you need to lookup how something in the stdlib works, you get more exposure to what good code ought to look like.
Post reply on HN