when i run my code in codechef is right but when i submit it is wrong WHY??

My code for atm problem:
try:
x,y= map(str,input().split(’ '))
x= int(x)
y= float(y)
if x<= y-0.50 and x%5==0:
a = y-x-0.50
w = format(a,".2f")
print(w)
else:
z= format(y,".2f")
print(z)
except:
pass

1 Like

Hi @riteshcode9728

Please check out the video editorial for this problem, I hope that will help you out!
HS08TEST | ATM | Coding with Logic : CP Problems Solved | CodeChef

Happy Coding!