a,b = map(int,input().split()) Or = a | b And = a & b print(int(Or)+int(And))