제출 #728285

#제출 시각아이디문제언어결과실행 시간메모리
728285MBI콤보 (IOI18_combo)C++17
10 / 100
81 ms456 KiB
#include "combo.h" #include <iostream> using namespace std; string guess_sequence(int N) { int l=0; string p="A"; do { int k=press(p); if (k>l){ l=k; p+="A"; continue; } if (k==l){ if (p.back()=='A') p.back()='B'; else if (p.back()=='B') p.back()='X'; else p.back()='Y'; } } while (l<N); p.pop_back(); // cerr << p << " (ans)"; return p; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...