随笔分类 -  字典树

摘要:String 阅读全文
posted @ 2018-08-16 09:35 Caturra 阅读(206) 评论(0) 推荐(0)
摘要:【FOTILE模拟赛】L 阅读全文
posted @ 2018-08-13 02:57 Caturra 阅读(196) 评论(0) 推荐(0)
摘要:Alo 阅读全文
posted @ 2018-08-13 00:54 Caturra 阅读(137) 评论(0) 推荐(0)
摘要:Remember the Word 阅读全文
posted @ 2018-04-05 14:57 Caturra 阅读(164) 评论(0) 推荐(0)
摘要:题意:给定$a[1...n]$,求$(a_i⊕a_i+1⊕...⊕a_j)+(a_p⊕a_{p+1}⊕...⊕a_{q})$的最大值,其中$1≤i≤j= 0; k ){ c=((x k)&1); if(!ch[now][c]){ ch[tot][0]=ch[tot][1]=0; sz[tot]=0; 阅读全文
posted @ 2018-02-08 01:24 Caturra 阅读(180) 评论(0) 推荐(0)
摘要:```C++ /*H E A D*/ struct Trie{ int son[maxn>i)&1; rrep(i,32,0){ if(!son[now][b[i]]){ son[now][b[i]]=++tot; son[tot][0]=son[tot][1]=0; ... 阅读全文
posted @ 2018-02-08 00:53 Caturra 阅读(109) 评论(0) 推荐(0)
摘要:```C++ / H E A D / struct Trie{ int son[maxn i)&1; rrep(i,32,0){ if(!son[now][b[i]]){ son[now][b[i]]=++tot; son[tot][0]=son[tot][1]=0; } now=son[now][ 阅读全文
posted @ 2018-02-07 15:47 Caturra 阅读(104) 评论(0) 推荐(0)
摘要:异或关于前缀的特性:[u,v]=[1,u]^[1,v] 注意是路径,假设1为根,prexor[1]不保留数值 C++ / H E A D / int to[maxn =1; } rrep(i,31,0){ if(!son[now][b[i]]) son[now][b[i]]=++tot; now=s 阅读全文
posted @ 2018-02-07 00:12 Caturra 阅读(163) 评论(0) 推荐(0)