Exercise 5-3 K & R