+ 2
Why doesn't this code run?
https://code.sololearn.com/c074jQuHDR74/#java It is the problem #3 of Project Eular (https://www.projecteular.net). The program runs fine with a low value for 'number'.
2 Answers
+ 3
@Gamma Guy please comment out the package line, I can get your code to run in Code Playground with it being commented, maybe Code Playground limit?
+ 1
Ipang, sorry I forgot to comment it before as I was working on it in BlueJ and copied the code here for help.
Yes, Code Playground has a limit but copy this code and run it on an IDE on your computer and then it will show "java.lang.ArithmeticException: / by zero" in line 15.