A, B = map(int, input().strip().split(' '))
print((A | B) + (A & B))