Problem 31 completed