solve exercise 40.08