Hacker News new | past | comments | ask | show | jobs | submit login

From Code Complete:

    “The smaller part of the job of programming is writing a program so that the computer can read it; the larger part is writing it so that other humans can read it.” (P.733)
Has stayed with me for ~20 years.



"Programs are meant to be read by humans and only incidentally for computers to execute."

From the preface to the first edition of Structure and Interpretation of Computer Programs by Abelson & Sussman (which predated Code Complete by a decade).

It's a maxim I live by although my employers always seem to insist on the computers executing part for some reason.


The computer executing part is the one that's both necessary and sufficient. The human reading part is neither. It's nice, important, and long-term indispensable - exactly the kind of thing economic pressures fight against.


The point (or at least as I read it) is that the human readability is more about the language being used.

The "necessary and sufficient" part is binary, and we're not doing that by hand any more.


I wish that wasn't buried on page 733!


The whole books has some good nuggets but it definitely makes you work for it :)


Or from Abelson (one of the SICP authors) similar, approximately:

Code should be written for humans to understand and only lastly for computers to understand.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: