Add solution of exercise 1.2.