Submission #987141

# Submission time Handle Problem Language Result Execution time Memory
987141 2024-05-22T05:05:48 Z lyu Poi (IOI09_poi) C++17
0 / 100
205 ms 12112 KB
#include <bits/stdc++.h>
using namespace std;

int main() {
    ios_base::sync_with_stdio(0);
    cin.tie(0);
    int n, t, p;
    cin >> n >> t >> p;
    p--;
    vector<int> points(t, n);
    vector<int> task(n, 0);
    bool correct[n][t];
    for(int i = 0; i < n; i++) {
        for(int j = 0; j < t; j++) {
            cin >> correct[i][j];
            if(correct[i][j]) {
                points[j]--;
                task[i]++;
            }
        }
    }
    vector<int> score(n, 0);
    for(int i = 0; i < n; i++) {
        for(int j = 0; j < t; j++) score[i] += correct[i][j]*points[j];
    }
    int front = 0;
    for(int i = 0; i < n; i++) {
        if(i == p) continue;
        if(score[i] > score[p]) front++;
    }
    front++;
    cout << n-front << ' ' << front << '\n';
}
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 344 KB Output isn't correct
2 Incorrect 1 ms 344 KB Output isn't correct
3 Incorrect 1 ms 348 KB Output isn't correct
4 Incorrect 1 ms 604 KB Output isn't correct
5 Incorrect 1 ms 348 KB Output isn't correct
6 Incorrect 1 ms 348 KB Output isn't correct
7 Incorrect 1 ms 348 KB Output isn't correct
8 Incorrect 1 ms 344 KB Output isn't correct
9 Incorrect 1 ms 344 KB Output isn't correct
10 Incorrect 3 ms 344 KB Output isn't correct
11 Incorrect 7 ms 600 KB Output isn't correct
12 Incorrect 11 ms 860 KB Output isn't correct
13 Incorrect 41 ms 2132 KB Output isn't correct
14 Incorrect 49 ms 2804 KB Output isn't correct
15 Incorrect 78 ms 4720 KB Output isn't correct
16 Incorrect 86 ms 4960 KB Output isn't correct
17 Incorrect 125 ms 7264 KB Output isn't correct
18 Incorrect 140 ms 8212 KB Output isn't correct
19 Incorrect 191 ms 10836 KB Output isn't correct
20 Incorrect 205 ms 12112 KB Output isn't correct