제출 #92982

#제출 시각아이디문제언어결과실행 시간메모리
92982beso123콤보 (IOI18_combo)C++14
0 / 100
67 ms220 KiB
#include <bits/stdc++.h> #include "combo.h" using namespace std; string a="ABXY"; string guess_sequence(int N){ string s; int r=1; while(s.size()<=N){ for(int k=0;k<a.size();k++){ string b=s+a[k]; if(press(b)==r){ s=b; r++; break; } } } return s; }

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

combo.cpp: In function 'std::string guess_sequence(int)':
combo.cpp:9:15: warning: comparison of integer expressions of different signedness: 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'} and 'int' [-Wsign-compare]
    9 | while(s.size()<=N){
      |       ~~~~~~~~^~~
combo.cpp:10:14: warning: comparison of integer expressions of different signedness: 'int' and 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   10 | for(int k=0;k<a.size();k++){
      |             ~^~~~~~~~~
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...