# Sereja and Array

# Sereja and Array

Sereja has got an array, consisting of **n** integers `a`

, _{1}`a`

, ..., _{2}`a`

. Sereja is an active boy, so he is now going to complete _{n}**m** operations. Each operation will have one of the three forms:

- Make
`v`

-th array element equal to_{i}`x`

. In other words, perform the assignment_{i}`a`

=_{vi}`x`

._{i} - Increase each array element by
`y`

. In other words, perform_{i}**n**assignments`a`

=_{i}`a`

+_{i}`y`

(_{i}**1**≤**i**≤**n**). - Take a piece of paper and write out the
`q`

-th array element. That is, the element_{i}`a`

._{qi}

Help Sereja, complete all his operations.

#### Input

The first line contains integers **n**, **m** (**1** ≤ **n**, **m** ≤ `10`

). The second line contains ^{5}**n** integers `a`

, _{1}`a`

, ..., _{2}`a`

(_{n}**1** ≤ `a`

≤ _{i}`10`

) - the original array.^{9}

Next **m** lines describe operations, the**i**-th line describes the **i**-th operation. The first number in the **i**-th line is integer `t`

(_{i}**1** ≤ `t`

≤ _{i}**3**), that represents the operation type. If `t`

= _{i}**1**, then it is followed by two integers `v`

and _{i}`x`

(_{i}**1** ≤ `v`

≤ _{i}**n**, **1** ≤ `x`

≤ _{i}`10`

). If ^{9}`t`

= _{i}**2**, then it is followed by integer `y`

(_{i}**1** ≤ `y`

≤ _{i}`10`

). And if ^{4}`t`

= _{i}**3**, then it is followed by integer `q`

(_{i}**1** ≤ `q`

≤ _{i}**n**).

#### Output

For each third type operation print value `a`

. Print the values in the order, in which the corresponding queries follow in the input._{qi}

10 11 1 2 3 4 5 6 7 8 9 10 3 2 3 9 2 10 3 1 3 10 1 1 10 2 10 2 10 3 1 3 10 3 9

2 9 11 20 30 40 39