Depth of Code

Hani’s blog

Book: A Philosophy of Software Design

Oct 1, 2021

A Philosophy of Software Design is a book written by John Ousterhout, a well-accomplished Standford University professor, who’s also known for creating the Tcl scripting language and the Raft consensus algorithm.

A Philosophy of Software Design

Here’s a summary of the ideas in the book:

The nature of complexity

Working code is not enough

Modules should be deep

Information hiding (and leakage)

General-purpose modules are deeper

Different layer, different abstraction

Pull complexity downwards

Better together, or better apart ?

Define errors out of existence

Design it twice

Why write comments ? The four excuses

Comments should describe things that aren’t obvious from the code

Choosing names

Write the comment first

*Modifying existing code

Consistency

Code should be obvious

Designing for performance