제출 #1324400

#제출 시각아이디문제언어결과실행 시간메모리
1324400riafhasan2010콤보 (IOI18_combo)C++17
0 / 100
1 ms388 KiB
#include "combo.h" using namespace std; std::string guess_sequence(int N) { string alpha, p = ""; if (press("A")) p += 'A', alpha = "BXY"; else if (press("B")) p += 'B', alpha = "AXY"; else if (press("X")) p += 'X', alpha = "ABY"; else p += 'Y', alpha = "ABX"; for (int i = 0; i < N; i++) { p += p[0]; for (int j = 0; j < 2; j++) { p[i] = alpha[j]; if (press(p) == i + 1) { break; } p[i] = alpha[2]; } } return p; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...