几枚专题

字典树水题几枚

1.HDU 1251 统计难题 很裸的一道字典树,直接输出个数的, 其实用map也能水过,只不过效率有些低 map版本 map做法就是把每个字符串的所有前缀遍历一遍,然后存起来,最后直接数个数就行。 具体代码吐下  很久很久以前的代码  很挫 #include <iostream>#include <vector>#include <list>#include <map>#i