# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
1146670 | kvintsekstakord | Combo (IOI18_combo) | C++20 | 0 ms | 396 KiB |
#include "combo.h"
using namespace std;
string chars = "ABXY";
string guess_sequence(int N) {
string S = "";
for(int i = 0; i < 4; i++){
int res = press(to_string(chars[i]));
if(res) S+=chars[i];
}
for(int i = 0; i < N-1; i++){
for(int j = 0; j < 4; j++){
if(chars[j]==S[0]) continue;
int res = press(S+chars[j]);
if(res==S.length()+1) S+=chars[j];
}
}
return S;
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |