In a few weeks I will be teaching again my Introductory Programming course at ETH, based for the first time on the published “Touch of Class” textbook . For fun (mine if no one else’s) every lecture will conclude with a haiku summarizing the topic.
I made up a few, given below, and am opening a competition for more. Every proposal should be submitted in the form of a comment to this post. Every winner’s haiku and name will appear in the course slides, and in the special Programming Haiku page which will be added to the book’s site. There are four rules:
- The contribution has to be a proper haiku: “three unrhymed lines of five, seven, and five syllables”.
- It must summarize the principal concept of a chapter or main section of the textbook or, better yet, of one of the course’s lectures; see  for the lecture plan.
- It must give the book reference (chapter or section) or lecture number or both.
- The prize committee’s members are secret and its judgments final.
Here, for a start, are my own examples.
Proof of the undecidability of the halting problem
Section 7.5 of the book; lecture 5.2.
If it stops, it loops,
Yet if it looped, it would stop.
Chapter 14, especially section 14.3; lecture 9.1.
Often, I call you.
But when the going gets tough,
I will call myself.
Chapter 15; lectures 11.1 and 11.2.
Partial to total?
With the right data structures,
O of m plus n.
Section 16.3; lecture 8.1.
How many to screw a bulb?
Section 16.5; lecture 8.1.
Do not implement!
Though for a truly Zen spec
You need a contract.
 Touch of Class: An Introduction to Programming Well Using Objects and Contracts, Springer Verlag, 2009. See Amazon page (still wrongly says the book is not yet published).