add solution to problem 9
add solution to #10