solved problem 12 and 13, add another solution to problem 10