Prabros. crimson logo

Prabros.

Cover of the Little Schemer

The Little Schemer Review

Daniel P. Friedman and Matthias Felleisen

Buy the Book

Intro

I read the book after completing How to Design Programs. So please keep in mind that these are the thoughts of someone who has had some prior amount of experience with Lisp language and functional programming. This means prior exposure to some of the concepts introduced in the book.

The Pedagogy

Little Schemer has a quirky style when it comes to teaching programming concepts. For a complete beginner, a lot of room is left for thought and figuring out. The book introduces the machinery of programming: list data structure, branching logic via conditional forms and recursion within three chapters. From that point onwards, various algorithms are introduced on data structures. By the fifth chapter, nested recursion on data structures star functions like member* that fractally recurses on lists are introduced. Some of these operations on nested lists can get a bit challenging and fun to solve.

Solid Engineering Practices

The idea of evaluating numerical expressions taught throughout the book gives one an idea of how to continuously iterate a codebase. The advantages of having well-named helper functions are illustrated with good examples. These provide a new programmer with opportunities to think about maintaining the programming interfaces of their code. It also sets up the stage to witness programs where a handful of functions interact together.

The Kickers

Some of the kickers in the book, well worth understanding deeply, are the ideas of currying and continuations. They introduce ways to abstract intermediate states of the program by making use of functions as values. I wished there were more examples on continuations, as a cursory reading on the Internet points to a lot of domains in which they find applications. As of late, continuations and their close cousin algebraic effects have found application in the popular front end library React.

Brusqueness and Loose Ends

There are some loose ends such as defining bijective functions, partial functions, Collatz conjecture, and Ackermann functions that are introduced brusquely without giving them the space for thinking they deserve. I guess these are left as topics for the follow-up book Seasoned Schemer to tie-in or as exercises for deeper research by the reader.

Meta Circularity

As one progresses through the book, one starts creating a repertoire of functions. These slowly build up a sense of culminating towards writing a Scheme compiler in Scheme. This meta-awareness of the environment and the data structures within delivers quite an intriguing feeling of how programming works as one progresses through the book.

One develops a feel for how a programming language can be bootstrapped by getting acquainted with these ideas. The chapter on metacircularity makes one reflect on the meta-layer mechanisms that were being used to encode the algorithms in the previous chapter.

Outro

If you are a total beginner, this might not be the best introduction to the world of programming. It has too much hand-holding and too little at times. This unevenness was okay for me as I have done a fair bit of functional programming. But I think this would be bumpy for a newcomer. But don't let that deter you from reading this book, it is chockfull of cool ideas that will leave you thinking and give fresh perspectives as you progress on your programming journey.

If you would like to read more book reviews like this from us, sign up to our newsletter!

Further Reading

Also, if you would like to read a blow-by-blow review of this as it happened, check out the Github repo for more details.

View Github Repository