problem 23 solution