Solved problem three