Skip to main content

Practice · 2 of 5

Range Max With Point Updates

CHALLENGE
Difficulty: intermediate+25 XP

**Bài toán.** Cho dãy a_1..a_n. Xử lý q thao tác: - 1 i x — gán a_i := x; - 2 l r — in max a_l..a_r. **Ràng buộc:** 1 ≤ n, q ≤ 200 000; −10^9 ≤ a_i, x ≤ 10^9.

Back to lesson: Practice: Segment Tree Problem Set