ATM prob. getting NZEC error

nzec_python

#1

code compiling and running fine
but getting runtime error(NZEC) while submission…frustrating

x,y=input().split(" ")
x=int(x)
y=float(y)
if x%5==0 and x<y:
y=y-x-0.5
print(y)
else:
print(y)


#2

Yeah, this is getting more frustrated for CodeChef beginners. Considering Python3 is becoming a commonly used language in the programming world, why not let input() work. I tried almost everything possible. I guess this is part of becoming a good programmer and not getting result forever.

Can someone provide an answer? Or


#3

@vickyvivek I figured out the issue, but not convinced. Try to use only split() instead of split(" "). Split function by default uses whitespace, newline, carriage return, tab and form feed as a separator.

Though I tried with all the separators explicitly as arguments, expecting one of them will work but it did not. So it’s quite inconsistent and unwelcoming for beginners.