| # | Time | Username | Problem | Language | Result | Execution time | Memory |
|---|---|---|---|---|---|---|---|
| 412749 | A_D | 크레이피쉬 글쓰는 기계 (IOI12_scrivener) | C++14 | 1093 ms | 5436 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
using namespace std;
const int N=5e3+100;
int cnt=1;
string s;
string tr;
vector<int> vec;
void Init() {}
void TypeLetter(char L){
tr+=L;
}
void UndoCommands(int U){
tr+='U';
vec.push_back(U);
}
char GetLetter(int P){
if(cnt){
cnt=0;
while(tr.empty()==0){
char u=tr.back();
tr.pop_back();
if(u=='U'){
int x=vec.back();
vec.pop_back();
while(x--){
tr.pop_back();
}
}
else{
s+=u;
}
}
reverse(s.begin(),s.end());
}
cout<<s[P];
}
Compilation message (stderr)
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
