字典树
文章平均质量分 76
double1994
这个作者很懒,什么都没留下…
展开
-
POJ 2001 Shortest Prefixes
字典树模板题,没啥好说的。只是为了记录下模板。 #include #include #include #include using namespace std; const int sonnum=26,base='a'; struct Trie { int x; int num; bool terminal; struct Trie *son[sonnum]; }原创 2013-08-26 16:57:56 · 434 阅读 · 0 评论 -
安大oj 673 聪明的输入法
字典树模板题,表示很简单,只是看不懂题。。。 #include #include #include #include using namespace std; typedef long long LL; #define N 100005 char a[N][15]; int n; int ptr; struct Node { int son[27]; int ex; in原创 2014-03-26 23:29:06 · 772 阅读 · 0 评论