Add solution for Project Euler problem 9