solution to exercise 8