Problem hidden
This problem was hidden by Editorial Board member probably because it has incorrect language version or invalid test data, or description of the problem is not clear.

Problem hidden

QMAX2 - Giá trị lớn nhất ver2

no tags 

Hiện tại, bài tập này đã có trên online judge chính thức của VNOI, bạn có thể truy cập ở đây: https://oj.vnoi.info/problem/qmax2


Giống bài "Giá trị lớn nhất" ở trên.

Input

- n: số phần tử của dãy (n <= 50000).
- m: số lượng biến đổi và câu hỏi (m <= 100000).
+) biến đổi có dạng: 0 x y value
+) câu hỏi có dạng : 1 x y.

Output

Ghi ra trả lời cho lần lượt từng câu hỏi.

Example

Input:
6 3
0 1 3 3
0 4 6 4
1 1 6

Output:
4

Added by:Nguyen Dinh Tu
Date:2006-11-18
Time limit:1s
Source limit:50000B
Memory limit:1536MB
Cluster: Cube (Intel G860)
Languages:All except: ERL JS-RHINO NODEJS PERL6 VB.NET