scrivener.cpp:1:1: error: 'vector' does not name a type
1 | vector<char> c;
| ^~~~~~
scrivener.cpp:2:1: error: 'vector' does not name a type
2 | vector<int> dep, ptr;
| ^~~~~~
scrivener.cpp:3:1: error: 'vector' does not name a type
3 | vector<vector<int>> pa, ch;
| ^~~~~~
scrivener.cpp: In function 'void Init()':
scrivener.cpp:6:3: error: 'c' was not declared in this scope
6 | c.push_back('.');
| ^
scrivener.cpp:7:3: error: 'dep' was not declared in this scope
7 | dep.push_back(0);
| ^~~
scrivener.cpp:8:3: error: 'ptr' was not declared in this scope
8 | ptr.push_back(0);
| ^~~
scrivener.cpp:9:3: error: 'pa' was not declared in this scope
9 | pa.emplace_back(20, 0);
| ^~
scrivener.cpp:10:3: error: 'ch' was not declared in this scope; did you mean 'char'?
10 | ch.emplace_back(26, -1);
| ^~
| char
scrivener.cpp: In function 'void TypeLetter(char)':
scrivener.cpp:14:24: error: 'ptr' was not declared in this scope
14 | int y = L - 'a', x = ptr.back();
| ^~~
scrivener.cpp:15:7: error: 'ch' was not declared in this scope
15 | if (ch[x][y] == -1) {
| ^~
scrivener.cpp:16:24: error: 'c' was not declared in this scope
16 | int i = ch[x][y] = c.size();
| ^
scrivener.cpp:18:5: error: 'dep' was not declared in this scope
18 | dep.push_back(dep[x] + 1);
| ^~~
scrivener.cpp:19:5: error: 'pa' was not declared in this scope
19 | pa.emplace_back(20);
| ^~
scrivener.cpp:25:17: error: 'ch' was not declared in this scope
25 | ptr.push_back(ch[t][x]);
| ^~
scrivener.cpp:25:20: error: 't' was not declared in this scope
25 | ptr.push_back(ch[t][x]);
| ^
scrivener.cpp: In function 'void UndoCommands(int)':
scrivener.cpp:29:11: error: 'ptr' was not declared in this scope
29 | int i = ptr.size() - 1 - U;
| ^~~
scrivener.cpp: In function 'char GetLetter(int)':
scrivener.cpp:35:11: error: 'ptr' was not declared in this scope
35 | int i = ptr.back();
| ^~~
scrivener.cpp:37:9: error: 'dep' was not declared in this scope
37 | if (dep[pa[i][j]] >= P)
| ^~~
scrivener.cpp:37:13: error: 'pa' was not declared in this scope
37 | if (dep[pa[i][j]] >= P)
| ^~
scrivener.cpp:39:10: error: 'c' was not declared in this scope
39 | return c[i];
| ^