0_0_27342909_14456.cpp:4:1: error: expected ',' or ';' before 'int'
int trie[maxn][30],tot=1,end1[maxn],sum[maxn]={0};
^
0_0_27342909_14456.cpp: In function 'void insert1(char*)':
0_0_27342909_14456.cpp:12:12: error: 'trie' was not declared in this scope
if(trie[p][ch] == 0) trie[p][ch] =++tot;
^
0_0_27342909_14456.cpp:12:45: error: 'tot' was not declared in this scope
if(trie[p][ch] == 0) trie[p][ch] =++tot;
^
0_0_27342909_14456.cpp:13:9: error: 'sum' was not declared in this scope
sum[trie[p][ch]]++;
^
0_0_27342909_14456.cpp:13:13: error: 'trie' was not declared in this scope
sum[trie[p][ch]]++;
^
0_0_27342909_14456.cpp:16:5: error: 'end1' was not declared in this scope
end1[p]=true;
^
0_0_27342909_14456.cpp: In function 'int search1(char*)':
0_0_27342909_14456.cpp:24:11: error: 'trie' was not declared in this scope
p=trie[p][str[i]-'a'];
^
0_0_27342909_14456.cpp:27:12: error: 'sum' was not declared in this scope
return sum[p];
^
|