Exercise 21 modified