版本比较
论线段树 tag 的优先级
正文
增加 7 行删除 7 行
181 行未改动全部展开182183184185186186187188189190135 行未改动全部展开32632732832933033033133233333333433533633722 行未改动360361362363364364365366367368110 行未改动全部展开47948048148248348348448548648748748848949049049149249349422 行未改动181 行未改动全部展开#define cin fin
const int N = 1e6+5;
int n,q; int n,q;int a[N];
const int S = N<<2;const int INF = -(1e18)-5;135 行未改动全部展开{ cin >> n >> q; for(int i = 1; i <= n; i++) cin >> a[i];
init_tree(); build();
int op,l,r,x; while(q--) { cin >> op;22 行未改动#define cin fin
const int N = 1e6+5;
int n,q; int n,q;int a[N];
const int S = N<<2;const int INF = -(1e18)-5;110 行未改动全部展开signed main(){// freopen("P1253_2.in","r",stdin);// freopen("P1253_2.txt","w",stdout);
cin >> n >> q; for(int i = 1; i <= n; i++) cin >> a[i];
init_tree(); root = build(root,1,n);
int op,l,r,x; while(q--) { cin >> op;22 行未改动