IntermediateRating 1300
Range XOR Queries
Answer q questions: what is the XOR of the numbers from position l to r (counting from 1)?
Input
n and q; n integers; q lines 'l r'.
Output
q lines.
Sample 1
Input
4 3 1 3 4 8 1 2 2 4 1 4
Output
2 15 14
Sample 2
Input
1 1 7 1 1
Output
7
Output appears here