Solved problem 55 on PE