Finish problem 6