An array is given (specifically, its initial version). You need to answer two types of queries:
a_i[j] = x — Create a new version from the -th version, in which the -th element equals , and all other elements remain the same as in the -th version.
get a_i[j] — Output the value of the -th element in the -th version.
The number of elements in the array (1 \le n \le 10^5), followed by the elements of the array. Next is the number of queries (1 \le m \le 10^5), followed by queries. The format of the queries is given in the sample input. If there are already versions of the array, the new one receives the number k+1. Both the initial and newly created elements of the array are integers from to 10^9. The elements in the array are numbered from to .
For each query of type get, output the corresponding element of the required array version.
Example 1