solved exercise 1.5