Code and comments

Practical and theoretical aspects of software development

Book review: The Little Schemer by Daniel Friedman

The Little SchemerThis is an unusual book. The first thing to know is that it does not contain chapters that are made up of paragraphs. It is a list of problems. The only way to gain anything from this book is to do the problems. Sure you may look at the first few and think you get the idea, and feel like you are doing fine just by reading the problems and solutions and thinking about them. But it won’t be long until you realize that you have no idea what is going on, and worse, you won’t know where you lost the trail.

So don’t be lazy, if you are going to read this book, set up an interpreter, and start coding.

The second thing to know about this book is that it does not attempt to teach you the Scheme programming language. Which is good news, because you don’t really want to be a Scheme programmer. What this book does teach, however, is of interest to every programmer.

This book is about recursion, and recursion is not optional. Many problems are most effectively modeled with graphs and trees, and if you aren’t able to identify and implement the natural recursion that exists, you will write code that obscures the actual problem, and is harder to write, debug, and maintain. So if you are not comfortable with recursion, this book is an immediate need.

Of course, if you are a programmer that reads blogs, you wouldn’t admit to yourself that you are uncomfortable with recursion, so let me say it another way. Working through The Little Schemer will allow you to quickly identify the basic patterns of recursion problems, and to structure your code in the way that will most clearly reveal that pattern.

I encountered recursive thought first in pure mathematics, where very similar thought is required in mathematical induction. Encountering recursion in programming was like meeting an old friend’s identical twin. The similarities were enough to make me feel more familiar than I was. As a result, my recursive solutions always felt ad hoc, and distinct to the particular problem, rather than following a well-established path.

Regardless of your background, if you are a programmer, or hope to someday be a programmer, and you have any hesitation in implementing recursive solutions, you should work through this book.


Written by Eric Wilson

January 2, 2012 at 7:38 am

Posted in reviews

Tagged with , , ,

4 Responses

Subscribe to comments with RSS.

  1. […] Book review: The Little Schemer by Daniel Friedman Appena finisco le cose in corso e quelle messe temporaneamente in stand-by e, dopo aver masterizzato Haskell (prima di mai, davvero) mi sa che mi dedico a questo, prendendo n piccioni: perfezionare Scheme e la ricorsivit√†, migliorare il mio stile, poter dire di averlo letto… ::: Code and comments […]

  2. I don’t think you should identify recursion == induction to the degree that you do. I think a much more accurate (and enlightening) statement is that every recursive definition suggests (usually rightly) an inductive proof. Recursion looks back; induction looks forward. Recursion breaks apart; induction builds.


    January 4, 2012 at 11:13 pm

    • Good point. I’ve weakened the identification. Thanks for a useful clarification.

      Eric Wilson

      January 6, 2012 at 12:22 pm

  3. […] At some point in your computer science education you were probably exposed to Lisp. Perhaps you worked through part of the SICP book, or maybe The Little Schemer. If not, I highly recommend the latter. […]

Comments are closed.

%d bloggers like this: