Code for problem 69C.