solve problem 23