看到这个题第一眼没思路,第二眼直接上线段树区间修改,看了题解发现怪不得这题难度是简单最高赞题解妙啊 #include <bits/stdc++.h> template<class T> struct Segt { struct node { int l, r; T w, rmq, lazy; }; std::vector<T> w; std::vector<node> t; Segt() {} Segt(int n) { init(n); } ...