added and completed problem 20