Project Euler in java first 10 problems