print((lambda x: x[1]^x[0])([int(i)for i in input().split()]))