a,b=map(int,input().split())
A,B=a%2>0,b%2<1
print(a*A^((b-B-(a-1^A))//2%2)^b*B) a,b=map(int,input().split()) a map(int,input().split()) map int input().split() ().split () input split b A,B=a%2>0,b%2<1 A a%2>0 a%2 a 2 0 B b%2<1 b%2 b 2 1 print(a*A^((b-B-(a-1^A))//2%2)^b*B) print a*A^((b-B-(a-1^A))//2%2)^b*B a*A^((b-B-(a-1^A))//2%2) a*A a A (b-B-(a-1^A))//2%2 (b-B-(a-1^A))//2 b-B-(a-1^A) b-B b B a-1^A a-1 a 1 A 2 2 b*B b B B=a%2>0,b%2<1 b%2<1 B A,B=a%2>0,b%2<1 a%2>0 A b=map(int,input().split()) map(int,input().split()) b a,b=map(int,input().split()) map(int,input().split()) a
a,b=map(int,input().split())
A,B=a%2>0,b%2<1
print(a*A^((b-B-(a-1^A))//2%2)^b*B)