solve problem 34