제출 #992145

#제출 시각아이디문제언어결과실행 시간메모리
992145spycoderyt콤보 (IOI18_combo)C++17
10 / 100
41 ms992 KiB
#include "combo.h" #include <bits/stdc++.h> using namespace std; std::string guess_sequence(int N) { vector<char> v = {'A','B','X','Y'}; string p = "",tmp; int cur=0; for(int i = 0;i<N;i++) { int ch = 0; for(int k = 0;k<4;k++) { if(i>0 && v[k] == p[0]) continue; tmp = p + v[k]; int res = press(tmp); if(res>cur){ cur = res; p = tmp; ch = 1; break; } } if(!ch)return p; } return p; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...