Submission #1132234

#TimeUsernameProblemLanguageResultExecution timeMemory
1132234bobthescienceCombo (IOI18_combo)C++20
Compilation error
0 ms0 KiB
#include<bits/stdc++.h> #include "combo.h" using namespace std; std::string guess_sequence(int N) { string p = ""; int r = 1, ord; vector<char> add = {'A', 'B', 'X', 'Y'}; for (int i = 0;i < 4;i++) { if (press("" + add[i])) { add.erase(add.begin() + i); break; } while (r < N) { for (char c :add) { if (press(p + c) > r) { r++; p += c; break; } } } return p; }

Compilation message (stderr)

combo.cpp: In function 'std::string guess_sequence(int)':
combo.cpp:25:2: error: expected '}' at end of input
   25 | }
      |  ^
combo.cpp:6:35: note: to match this '{'
    6 | std::string guess_sequence(int N) {
      |                                   ^
combo.cpp:25:2: warning: control reaches end of non-void function [-Wreturn-type]
   25 | }
      |  ^