Submission #1148971

#TimeUsernameProblemLanguageResultExecution timeMemory
1148971ali2241Combo (IOI18_combo)C++20
Compilation error
0 ms0 KiB
#include "combo.h"
#include <bits/stdc++.h>
// #define int long long
#define arr2 array<int, 2>
#define arr3 array<int, 3>
#define all(a) a.begin(), a.end()
#define double long double
// #pragma GCC target("avx2")

using namespace std;

const int N = 401, M = 1e9 + 7;

string s;

string guess_sequence(int n) {
    return s;
}

char chs[4] = {'A', 'B', 'X', 'Y'};

void fun() {
    int n;
    cin >> n;
    for (int i = 0; i < n; ++i) {
        for (int j = 0; j < 4; ++j) {
            if (press((string)(s + chs[j])) > s.size()) {
                s += chs[j];
                break;
            }
        }
    }
}

int32_t main() {
    // ios::sync_with_stdio(0);
    // cin.tie(0); cout.tie(0);
    // int tc;
    // cin >> tc;
    // while (tc--)
    fun();
}

Compilation message (stderr)

/usr/bin/ld: /tmp/cc5xxRN4.o: in function `main':
grader.cpp:(.text.startup+0x0): multiple definition of `main'; /tmp/ccetsIW7.o:combo.cpp:(.text.startup+0x0): first defined here
collect2: error: ld returned 1 exit status