Exercise 10 modified