Solved exercise 21.