C, Y = map(int, input().split()) if 100 * C > Y: print("can't exchange") elif (Y % 500) // 100 >= C: print("no exchange") else: print(C)