Shows error while compiling but accept code while submission

when I run the code before submission, it shows runtime error(NZEC) but after submitting code it gets accepted. Can anyone tell me the reason?
code link- https://www.codechef.com/viewsolution/26288061

because you did not give custom input
before clicking on run
from now on try copy pasting the input and then click on run

2 Likes

means for every time while compiling the code i have to give the custom input?

yess
for every input statement there should be appropriate input

1 Like

ok. thanks for the info.