제출 #99110

#제출 시각아이디문제언어결과실행 시간메모리
99110JustasLe콤보 (IOI18_combo)C++17
10 / 100
92 ms488 KiB
#include "combo.h";
#include <bits/stdc++.h>

using namespace std;

string guess_sequence(int N) {
	set<char> X = {'A', 'B', 'X', 'Y'};
	string s = "";
	for (auto it = X.begin(); it != X.end(); it++) {
		int x = press(s + *it);
		if (x != 0) {
			s += *it;
			X.erase(it);
			break; 
		}
	}
	int prev = 1;
	bool ok = true;
	while (ok) {
		ok = false;
		for (auto it = X.begin(); it != X.end(); it++) {
			string poss = s + *it;
			int x = press(poss);
			if (x > prev) {
				s = poss;
				ok = true;
				prev = x;
				break;
			}
		}
	}
	return s;
}

컴파일 시 표준 에러 (stderr) 메시지

combo.cpp:1:19: warning: extra tokens at end of #include directive
    1 | #include "combo.h";
      |                   ^
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...