""" 想定解? """ C,Y = map(int,input().split()) Y //= 100 if Y < C: print ("can't exchange") elif Y % 5 >= C: print ("no exchange") else: print ( (Y-C) % 5 + C )