Little Gyro has just found an integer array A = {

} in his left pocket, As Little Gyro is bored, he decides to play with the array.
Then, Little Gyro is about to do the following two operations:
1. 1 L R K D : Given an arithmetic sequence with its length R-L+1, the first item of this sequence is K, and its tolerances is D, then Little Gyro will add this sequence to

of array A within the corresponding position. For example:

,

,

,……,
D)
.
2. 2 P : Query the value of the P-th number

of the array A.
Given an integer array A with its length n, after m operations, for each query, Little Gyro wants to know the value of the array elements and ask you for help, please help him to calculate the answer.
输入描述:
Each input file only contains one test case.
The first line contains two integers n, m (1 ≤ n, m ≤
), indicating the length of the array and the number of the operations.
The second line contains n integers
(
≤ 200), indicating the given array.
In the following m lines, each line contains one operation, within the following two formats which described above:
1 L R K D (| K | ≤ 200, | D | ≤ 200, 1 ≤ L ≤ R ≤ n)
2 P (1 ≤ P ≤ n)
输出描述:
For each query output an integer indicating the value of
from the current array A.
示例1
输入
复制
5 2
1 2 3 4 5
1 2 4 1 2
2 3