随笔分类 - ACM--字符串--字典树
摘要:Chip Factory AC_Code: 1 #include <iostream> 2 #include <cstring> 3 #include <cstdio> 4 #include <cmath> 5 #include <algorithm> 6 using namespace std;
阅读全文
摘要:参考博客:https://blog.csdn.net/weixin_43847416/article/details/95048031 https://blog.csdn.net/qq_41292370/article/details/90680145 01字典树主要用于解决求异或最值的问题。01字
阅读全文
摘要:如图为一颗字典树,该树插入了7个单词,abc,abcd,b,bcd,efg,hij 字典树模板: 1 #include <bits/stdc++.h> 2 using namespace std; 3 const int maxn=2e6+5; // Trie 树上的最大结点数 4 5 int to
阅读全文