Submission #138167

#TimeUsernameProblemLanguageResultExecution timeMemory
138167ly20Combo (IOI18_combo)C++17
5 / 100
5 ms280 KiB
#include "combo.h" #include <bits/stdc++.h> using namespace std; map<int,char> mp; string guess_sequence(int N) { string p=""; for(int i=0;i<N;i++)p.push_back('A'); mp[0]='A'; mp[1]='B'; mp[2]='X'; mp[3]='Y'; for(int i=0;i<4;i++) { for(int j=0;j<4;j++) { for(int k=0;k<4;k++) { p[0]=mp[i];p[1]=mp[j];p[2]=mp[k]; if(press(p)==N)return p; } } } }

Compilation message (stderr)

combo.cpp: In function 'std::string guess_sequence(int)':
combo.cpp:27:1: warning: control reaches end of non-void function [-Wreturn-type]
   27 | }
      | ^
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...