0_0_34377994_11433.cpp:34:5: error: 'string' does not name a type
string res; ST st;
^
0_0_34377994_11433.cpp:68:22: error: 'string' does not name a type
void build(const string& s) {
^
0_0_34377994_11433.cpp: In member function 'void SA::rsort(int*, int, int, int*, int*)':
0_0_34377994_11433.cpp:37:43: error: 'memset' was not declared in this scope
memset(c, 0, sizeof(int) * (m + 1));
^
0_0_34377994_11433.cpp: In member function 'void SA::build(int*, int, int)':
0_0_34377994_11433.cpp:50:38: error: 'memset' was not declared in this scope
memset(c, 0, sizeof (int) * m);
^
0_0_34377994_11433.cpp:51:38: error: 'memcpy' was not declared in this scope
memcpy(rk, r, sizeof(int) * n);
^
0_0_34377994_11433.cpp:60:22: error: 'swap' was not declared in this scope
swap(x, y);
^
0_0_34377994_11433.cpp:65:33: error: 'swap' was not declared in this scope
if (x != rk) swap(rk, se);
^
0_0_34377994_11433.cpp: In member function 'void SA::build(const int&)':
0_0_34377994_11433.cpp:70:30: error: 'begin' was not declared in this scope
for (const auto& i : s) sv[cnt++] = i;
^
0_0_34377994_11433.cpp:70:30: error: 'end' was not declared in this scope
0_0_34377994_11433.cpp:71:9: error: 'res' was not declared in this scope
res = s;
^
0_0_34377994_11433.cpp: In member function 'void SA::getH()':
0_0_34377994_11433.cpp:76:17: error: 'res' was not declared in this scope
int n = res.length(), k = 0, j;
^
0_0_34377994_11433.cpp:77:45: error: 'k' was not declared in this scope
for (int i = 0; i < n; heigh[i++] = k)
^
0_0_34377994_11433.cpp:78:31: error: 'j' was not declared in this scope
for (k ? --k : 0, j = sa[rk[i] - 1];
^
0_0_34377994_11433.cpp: In member function 'int SA::solve(int)':
0_0_34377994_11433.cpp:88:25: error: 'res' was not declared in this scope
getH(); int n = res.length();
^
0_0_34377994_11433.cpp:109:67: error: 'max' was not declared in this scope
if (pre < val and aft < val) ans += val - max(pre, aft);
^
0_0_34377994_11433.cpp: In function 'int main()':
0_0_34377994_11433.cpp:117:5: error: 'ios' has not been declared
ios::sync_with_stdio(false);
^
0_0_34377994_11433.cpp:118:5: error: 'cin' was not declared in this scope
cin.tie(nullptr);
^
0_0_34377994_11433.cpp:122:9: error: 'string' was not declared in this scope
string s; cin >> s;
^
0_0_34377994_11433.cpp:122:26: error: 's' was not declared in this scope
string s; cin >> s;
^
0_0_34377994_11433.cpp:124:9: error: 'cout' was not declared in this scope
cout << sa.solve(k) << endl;
^
0_0_34377994_11433.cpp:124:32: error: 'endl' was not declared in this scope
cout << sa.solve(k) << endl;
^
|