Conveyer#11536

Conveyer

2 seconds
256 megabytes
Very hard

One day, Kich and Poch went to work at a factory. The first time they were in the factory, they were very surprised. First, it was very dusty, so their superpowers had little effect on the people around them. Secondly, they were bored to death, so they decided to play a game. For this, they chose a conveyor belt (which, for a completely unknown reason, was not working). On it lies parts of heights a_1, a_2, \dots, a_n.

Kich sets tasks for Poch, and he must fulfill them:

  1. Task «reverse »: Poch must work hard to reverse the segment of parts from to .

  2. Task «change »: Poch must change the height of the -th part from a_i to (i.e., make a_i:=x).

  3. Query «ask »: Poch should think hard and say whether the heights of the parts on the segment to are sorted strictly in ascending order.

However, Poch recently tried to do lab work on "OAIP" discipline (he ended up in the factory, of course) and he is incredibly lazy to follow Kich's commands, so he asked you to help him outsmart Kich so that he doesn't have to do anything by hand himself.

Input

In the first line you are given a positive integer n~(1 \le n \le 2 \cdot 10^5).

In the second line you are given integers a_i~(-10^9 \le a_i \le 10^9).

In the third line you are given one number q~(1 \le q \le 2 \cdot 10^5) — the number of queries.

The next lines contain the queries themselves in the format described above.

-10^9 \le x \le 10^9
1 \le i, l, r \le n

Output

For each "ask" query, print the answer to it — "Yes" (without quotes) if the part heights are sorted strictly in ascending order. Otherwise, output "No" (without quotes).

Examples

Example 1

Loading
Loading

Example 2

Loading
Loading