Project Euler Java 1.8 Functional Programming