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