Finished problem 1293 :)