CS51: Abstraction and Design in Computer Programming

CS51 Pithy Design Quotes

Week 0: Design and Abstraction in Computer Programs
"Programs must be written for people to read, and only incidentally for machines to execute." - Abelson & Sussman, SICP
Week 1: Introduction to Scheme
The K.I.S.S. Principle = Keep it simple, stupid! (anonymous)

Fools ignore complexity. Pragmatists suffer it. Geniuses remove it. (Alan Perlis, Epigrams)
Week 2: Functions as Abstractions
D.R.Y = Don't Repeat Yourself

Reuse is old code on new data
Week 3: Data as an Abstraction

Perfection is reached not when there is no longer anything to add, but when there is no longer anything to take away. (A. Saint-Exupery)

To understand a program you must become both the machine and the program. -- Alan Perlis

Week 4: Higher-Order Functions and the Streams Abstraction
The Plug and Socket Model = many types of appliances, many sources of power, one interface!
Week 5: Designing Your Own Advisor
Rules of Thumb for scheduling a software task
  • 1/3 planning
  • 1/6 coding
  • 1/4 component test and early system test
  • 1/4 system test, all components in hand
(Brooks, The Mythical Man-Month)

"Every program has (at least) two purposes: the one for which it was written, and another for which it wasn't." (Alan Perlis, Epigrams).

Week 6: Introduction to Objects

"I broke my arm trying to fold a bed. It wasn't the kind that folds."
--- Steven Wright on type errors

A programming language is low level when its programs require attention to the irrelevant.

Week 7: Object-Oriented Programming
Keep Secrets!

++ An interface *guides the user's thinking*. Interface design is about deciding what the user does and doesn't need to know.

-- Wherever there is modularity there is the potential for misunderstanding: Hiding information implies a need to check communication.

Week 8: Inheritance and Designing Type Heirarchies

Design your interfaces to be simple and logical - the "procedures" that run inside people's heads are just as important as those you explicitly write.

Premature optimization is the root of all evil (or at least most of it) in programming.-- Knuth

Week 9: Iterators, Exceptions and the Standard Template Library
I'll begin with a shockingly controversial statement: programming languages vary in power...all other things being equal, it is a mistake to program in anything but the most powerful one. (Paul Graham, Beating the Averages)
Week 10: Designing a Large Program

What makes a good programmer? The key is to REDUCE WASTED EFFORT AT EACH STAGE. (Liskov & Guttag)

Plan to throw one away; you will, anyhow (Brooks, The Mythical Man-Month)

Week 11: Language as an Abstraction
Programming languages are merely the most reusable programs; any program that gets sufficiently reusable starts to look like a programming language.