1 2 3 4
摘要: https://www.luogu.com.cn/problem/P3391 这平衡树太厉害了。 思想就是分裂成1--x-1 x y y n三段,然后给x y这段树打上lazy标记, 在合并和分裂时候都要先下传标记才行 具体看代码就好,留个模板记录一下 #include<iostream> #inc 阅读全文
posted @ 2020-11-07 16:32 Lesning 阅读(86) 评论(0) 推荐(0) 编辑
摘要: https://www.luogu.com.cn/problem/P3369 随机大法好啊啊啊 插入数字的时候,把平衡树按x分裂,插入x后再合并,具体可以看代码 #include<iostream> #include<algorithm> #include<cstdio> #include<ctim 阅读全文
posted @ 2020-11-07 10:55 Lesning 阅读(194) 评论(0) 推荐(0) 编辑