제출 #231298

#제출 시각아이디문제언어결과실행 시간메모리
231298blacktulip크레이피쉬 글쓰는 기계 (IOI12_scrivener)C++17
0 / 100
126 ms12128 KiB
#include <bits/stdc++.h> using namespace std; #define fi first #define se second #define mp make_pair #define pb push_back char c; //~ map<int,string> mpp; int cev,koy,say,flag; string s; vector< pair<int,int> > v; void Init(){ } void TypeLetter(char L){ v.pb(mp(say++,L-'a')); } void UndoCommands(int U){ v.pb(mp(U,-1)); } char GetLetter(int P){ if(flag==0){ reverse(v.begin(),v.end()); int yasak=0; for(int i=0;i<(int)v.size();i++){ if(yasak){yasak--;i++;continue;} if(v[i].se==-1)yasak=v[i].fi; else s+=v[i].se+'a'; } reverse(s.begin(),s.end()); flag=1; } return s[P]; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...