Submission #976514

#TimeUsernameProblemLanguageResultExecution timeMemory
976514marinalucaCrayfish scrivener (IOI12_scrivener)C++14
Compilation error
0 ms0 KiB
#include <bits/stdc++.h> #include <ext/rope> __gnu_cxx:crope c[1000100]; int k; void Init(){} void TypeLetter(char L){ k ++; c[k] = c[k - 1]; c[k].push_back(L); } void UndoCommands(int U){ k ++: s[k] = s[k - U - 1]; } char GetLetter(int P){ return s[k][P]; }

Compilation message (stderr)

scrivener.cpp:3:10: error: found ':' in nested-name-specifier, expected '::'
    3 | __gnu_cxx:crope c[1000100];
      |          ^
      |          ::
scrivener.cpp: In function 'void UndoCommands(int)':
scrivener.cpp:12:9: error: expected ';' before ':' token
   12 |     k ++:
      |         ^
      |         ;
scrivener.cpp: In function 'char GetLetter(int)':
scrivener.cpp:16:11: error: 's' was not declared in this scope
   16 |    return s[k][P];
      |           ^