s = input() s = list(s) a = int(s[-1]) a += 1 a %= 2 s[-1] = str(a) print("".join(s))