Submission #972466

#TimeUsernameProblemLanguageResultExecution timeMemory
972466androCrayfish scrivener (IOI12_scrivener)C++14
Compilation error
0 ms0 KiB
char last; void Init() {} string s = ""; void TypeLetter(char L) { s += L; } void UndoCommands(int U) { } char GetLetter(int P) { return s[p]; }

Compilation message (stderr)

scrivener.cpp:6:1: error: 'string' does not name a type
    6 | string s = "";
      | ^~~~~~
scrivener.cpp: In function 'void TypeLetter(char)':
scrivener.cpp:10:3: error: 's' was not declared in this scope
   10 |   s += L;
      |   ^
scrivener.cpp: In function 'char GetLetter(int)':
scrivener.cpp:20:10: error: 's' was not declared in this scope
   20 |   return s[p];
      |          ^
scrivener.cpp:20:12: error: 'p' was not declared in this scope
   20 |   return s[p];
      |            ^