Add solution to Problem 27.