NZEC - for java related code

I dont know what is wrong but everytime I try to submit a solution I get NZEC error. Code works great in eclipse/netbeans/IntelliJ or even notepad.

Please look at below solution

Its kind of frustrating to have a solution in front of eyes and not able to run it.