struct node{
int son[27];
int exist = false;
bool visited = false;
}nodes[900000];
int top = 0;
void insert(string str){
int num,root = 1;
for(int i = 0;str[i];i++){
num = str[i] - 'a';
if(nodes[root].son[num]==0)//no son
nodes[root].son[num] = ++top;
root = nodes[root].son[num];
}
nodes[root].exist = true;
}
int search(string str){
int num = 0,root = 1;
for(int i = 0;str[i];i++){
num = str[i]-'a';
if(nodes[root].son[num]==0)return WRONG;
root = nodes[root].son[num];
}
if(!nodes[root].exist)return WRONG;
else if(nodes[root].visited)return REPEAT;
nodes[root].visited = true;
return OK;
}
科研训练
# 寒假30篇论文计划 - [] 1、SEWResnet - [] 2、Resnet - [] 3、Spikeformer - [] 4、TVConv - [] 5、