Get the latest tech news

Kernighan's Lever (2012)


lever Brian Kernighan famously wrote: Everyone knows that debugging is twice as hard as writing a program in the first place. So if you're as clever as you can be when you write it, how will you ever debug it? — The Elements of Programming Style, 2nd edition, chapter 2 The following version also circulates on the net: Debugging is twice as hard as writing the code in the first place.

Not only the desire to deliver working software on time, but other powerful forces such as pride, stubbornness and curiosity contribute to the motivation that pushes you onwards through the arduous task of tracking down the root cause of the error. However, should you pick a starting point in the enjoyable flow area, Kernighan's lever will screech into action and push you sideways through the graph, increasing your skill until it matches the challenge posed by the bugs in your code. Interesting essay with some valid points, but the context lacks depth: it is one thing to do this because it is a hobby, quite another if one must walk the very delicate line of writing code easy to debug in consideration of others, because one is an entrepreneur, racing against the clock.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of Lever

Lever

Photo of Kernighan

Kernighan