Runtime error (NZEC)

I have written a program which executed successfully but then while submitting , I got the Runtime error (NZEC) .Can any one explain ?I am new to java btw

here is the link for my code -CodeChef: Practical coding for everyone

Same testcase as this guy, I think:

1 Like

@atul_khandekar Is Your Java Code Is Running Fine On Your Local Machine?
NZEC: Non Zero Exit Code

yes its working fine

Then Try Using Try Catch
And After Try Catch Codechef Will Give You Wrong Ans
Then You Solve Problem If Your Ans Is Correct It Will Give You Accepted