Input
The first line contains the size $N$ of the sequence. ($1 \le N \le 200{,}000$)
The second line contains $A_1, A_2, \ldots, A_N$. ($0 \le A_i < 2^{20}$)
The third line contains the number of queries $M$. ($1 \le M \le 200{,}000$)
The fourth through the $M$-th lines each contain a query. ($1 \le L \le R \le N$, $0 \le X < 2^{20}$) There is at least one query of type 3.
Output
For each query of type 3, output the result on a separate line.
Examples
Input 1
5 1 3 2 5 4 8 3 1 3 2 1 1 5 3 1 3 1 1 4 6 2 3 4 1 3 2 3 2 2 3 4 3 1 5
Output 1
3 5 3 7
Note
The sequence evolves as follows:
- 1, 3, 2, 5, 4
- 5, 3, 2, 5, 4
- 5, 3, 2, 5, 4
- 4, 2, 2, 4, 4
- 4, 2, 3, 5, 4
- 4, 2, 3, 5, 4
- 4, 6, 7, 5, 4
- 4, 6, 7, 5, 4