Solved problem 2.