solve exercise 22.11