Bob Nystrom personal blog

The Hardest Program I've Ever Written – How a code formatter works (2015)

The hardest program I’ve ever written, once you strip out the whitespace, is 3,835 lines long. That handful of code took me almost a year to write. Granted, that doesn’t take into account the code that didn’t make it. The commit history shows that I deleted 20,704 lines of code over that time. Every surviving line has…
Points
500
HN comments
471
Submissions
5
Cited by
17 commenters

Software Engineering2020

On Hacker News

SubmittedTitle on HNPointsComments
Mar 27, 2020The Hardest Program I've Ever Written – How a code formatter works (2015) by goranmoomin500125
Jun 9, 2018The Hardest Program I've Ever Written (2015) by tosh30376
Mar 5, 2022The hardest program I've ever written (2015) by graderjs261133
Sep 9, 2015The Hardest Program I've Ever Written by skybrian24276
Oct 29, 2025The hardest program I've ever written (2015) by jacobedawson9761

Cited in comments

Linked from 21 Hacker News comments by 17 different people, from Oct 2015 to Apr 2026.

Most recent:

Search every comment that links here →

More from Bob Nystrom

All 18 posts →

Related posts from the same era