solutions to problems from Euler Project in java