Submission #51349

#TimeUsernameProblemLanguageResultExecution timeMemory
51349classe88Game (IOI14_game)C++14
Compilation error
0 ms0 KiB
//https://oj.uz/problem/view/IOI14_game #include <iostream> #define N 1500 using namespace std; int A[N][N]; int sum[N]; int n; int hasEdge(int u, int v) { if (u < v) return hasEdge(v, u); if (sum[u] == n - u) { A[u][v] = 1; return 1; } else { sum[u] += 1; return 0; } } void initialize(int k) { n = k; for (int i = 0; i < N; i++) { for (int j = 0; j < N; j++) { A[i][j] = 0; } sum[i] = 0; } } int main() { int n; cin >> n; initialize(n); for (int i = 0; i < n*(n-1)/2; i++) { int u, v; cin >> u >>v; hasEdge(u, v); } return 0; }

Compilation message (stderr)

/tmp/ccu68snh.o: In function `main':
grader.cpp:(.text.startup+0x0): multiple definition of `main'
/tmp/ccOJjhG8.o:game.cpp:(.text.startup+0x0): first defined here
collect2: error: ld returned 1 exit status