一. 题目 487-3279 Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 274040 Accepted: 48891 Description Businesses like to have memorable telephone numbers. One way to make a telephone number memorable is to have it spell a memorable word or…
//字典树模板题.题意:给一个库,每次查询,求以之为前缀的单词数量. #include<iostream> #include<string> #include<vector> #include<cstdio> #include<cstring> using namespace std; int tree[500000][27]; int w[500000]; //记录结点属性. int numv=0; // 全局变量,记录顶点编号 int n;…