Programming Pearls - Problem 2.3