import sys readline=sys.stdin.readline A,B=map(int,readline().split()) ans=(A|B)+(A&B) print(ans)