You are given two positive integers X and Y of the same length in base 10. Z is defined as the positive integer in base 10 satisfying the following conditions.
You have to perform Q queries. Each query is one of the followings:
The i-th digit of a positive integer is defined from the left. For example, The third digit of 1234 is 3.
The first line contains two space-separated integers, X and Y.
The second line contains a single integer, Q.
The following Q lines contain space-separated integers describing the queries. Each line has one of the following forms, where the first integer represents the type of the query:
1 i x : Change the i-th digit of Y to x.2 i : Output the i-th digit of Z. If there is no such Z, print −1.It is guaranteed that there is at least one query of type 2.
For each query of type 2, output the answer for the query. The answers should be separated by newlines.
Let len(A) be the number of digits in a positive integer A.
len(X)=len(Y)len(Y), 0≤x≤9. If i=1, x=0.len(Y).