a, c = map(int, input().split()) print((a | c) - (a & c))