摘要: 两个锅 一个是sametag[i]==c 另一个是a[j]不要写成a[i] cpp include include include include using namespace std; int belong[100100],sametag[100100],n,a[100100],sz,block 阅读全文
posted @ 2018-11-30 19:58 dreagonm 阅读(228) 评论(0) 推荐(0) 编辑
摘要: pushdown的addtag[x]打成addtag[i],结果WA了一次 cpp include include include include using namespace std; const int MOD = 10007; int belong[100100],tagadd[100100 阅读全文
posted @ 2018-11-30 19:17 dreagonm 阅读(139) 评论(0) 推荐(0) 编辑
摘要: 真是暴力 cpp include include include include include using namespace std; vector Vec[600]; int stack[250000],belong[250000],n,cnt,cntinsert=0,sz,blocknum; 阅读全文
posted @ 2018-11-30 17:24 dreagonm 阅读(167) 评论(0) 推荐(0) 编辑
摘要: 平衡树的裸题,操作都相当简单 写了一个FHQ,但是奈何常数太大,实在过不去 最后写了一个Treap开O2水过 TREAP代码 cpp include include include include using namespace std; struct node{ int sz,key,ran,l, 阅读全文
posted @ 2018-11-30 00:18 dreagonm 阅读(166) 评论(0) 推荐(0) 编辑