exercise 1.40 completed