30452023-02-08 20:14:13xxxKártya (80 pont)cpp14Wrong answer 0/803ms3896 KiB
#include <bits/stdc++.h>
using namespace std;

int main() {
    int n;
    cin >> n;
    int a[n], b[n];
    int sum= 0;
    for(int i = 0; i < n; i++) {
        cin >> a[i];
        sum += a[i];
    }

    sum /= n;

    for (int i = 0; i < n;i++) {
        if ((a[i] - sum) > 0)
            cout << a[i] - sum << " ";
        else cout << 0 << " ";
    }

    return 0;

}
SubtaskSumTestVerdictTimeMemory
base0/80
1Wrong answer0/03ms1748 KiB
2Wrong answer0/03ms1908 KiB
3Wrong answer0/43ms1996 KiB
4Wrong answer0/53ms2120 KiB
5Wrong answer0/53ms2332 KiB
6Wrong answer0/53ms2576 KiB
7Wrong answer0/53ms2796 KiB
8Wrong answer0/43ms3032 KiB
9Wrong answer0/43ms3244 KiB
10Wrong answer0/53ms3328 KiB
11Wrong answer0/53ms3508 KiB
12Wrong answer0/53ms3648 KiB
13Wrong answer0/63ms3720 KiB
14Wrong answer0/63ms3868 KiB
15Wrong answer0/73ms3884 KiB
16Wrong answer0/73ms3772 KiB
17Wrong answer0/73ms3896 KiB