Added problem 7 solution