Submission #163033

#TimeUsernameProblemLanguageResultExecution timeMemory
163033rolypolyvg295Treasure (different grader from official contest) (CEOI13_treasure2)C++14
Compilation error
0 ms0 KiB
#include <iostream> #include <vector> #include <algorithm> #include <functional> using namespace std; int calculate(int y, int x, vector<vector<int>>&count){ return count[y][x] - count[y+1][x] - count[y][x+1] + count[y+1][x+1]; } int main(){ int n; cin >> n; vector<vector<int>> count(n+2, vector<int>(n+2, 0)); for (int i = 1; i <= n; i++) for (int j = 1; j <= n; j++){ cout << i << ' ' << j << ' ' << n << ' ' << n << endl; cin >> count[i][j]; } cout << "END" << endl; for (int i = 1; i <= n; i++){ for (int j = 1; j <= n; j++) cout << calculate(i, j, count); cout << '\n'; } cout << endl; return 0; }

Compilation message (stderr)

/tmp/cc68UBBQ.o: In function `main':
treasure.cpp:(.text.startup+0x0): multiple definition of `main'
/tmp/ccoIEtC6.o:grader.c:(.text.startup+0x0): first defined here
/tmp/ccoIEtC6.o: In function `main':
grader.c:(.text.startup+0x109): undefined reference to `findTreasure(int)'
collect2: error: ld returned 1 exit status