Submission #1142124

#TimeUsernameProblemLanguageResultExecution timeMemory
1142124alilouCombo (IOI18_combo)C++20
0 / 100
1084 ms408 KiB
#include<bits/stdc++.h>
#include "combo.h"

using namespace std;

string guess_sequence(int n){
    const int m=4;
    string buttons="ABXY";
    string s="";
    for(int i ; i<n ; i++){
        for(int j ; i<m-1 ; i++){
            int lenght=press(s+buttons[j]);
            if (lenght==i+1){
                s+=buttons[j];
                break;
            }
        if (s.size()!=i+1)s+=buttons[m-1];
        }
    s+=buttons[m-1];
    }


}

Compilation message (stderr)

combo.cpp: In function 'std::string guess_sequence(int)':
combo.cpp:23:1: warning: no return statement in function returning non-void [-Wreturn-type]
   23 | }
      | ^
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...