Project Euler Solutions in Javascript