제출 #216627

#제출 시각아이디문제언어결과실행 시간메모리
216627achvanov콤보 (IOI18_combo)C++17
10 / 100
111 ms584 KiB
#include <bits/stdc++.h> #include <combo.h> using namespace std; char c[] = {'A', 'B', 'X', 'Y'}; string guess_sequence(int n) { string res = ""; for (int i = 0; i < n; ++i) { for (int j = 0; j < 4; ++j) { if (press(res + c[j]) > res.size()) { res += c[j]; break; } } } return res; }

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

combo.cpp: In function 'std::string guess_sequence(int)':
combo.cpp:12:29: warning: comparison of integer expressions of different signedness: 'int' and 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   12 |       if (press(res + c[j]) > res.size()) {
      |           ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...