add test and code for problem 7 of Euler Project