Completed Euler #8 (js)