30442023-02-08 20:13:32xxxKártya (80 pont)cpp14Wrong answer 0/803ms3980 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 << " ";
    }


    cout << endl;
    return 0;

}
SubtaskSumTestVerdictTimeMemory
base0/80
1Wrong answer0/03ms1880 KiB
2Wrong answer0/03ms2120 KiB
3Wrong answer0/43ms2356 KiB
4Wrong answer0/53ms2516 KiB
5Wrong answer0/53ms2756 KiB
6Wrong answer0/53ms2748 KiB
7Wrong answer0/53ms2968 KiB
8Wrong answer0/43ms2972 KiB
9Wrong answer0/43ms2972 KiB
10Wrong answer0/53ms3100 KiB
11Wrong answer0/53ms3220 KiB
12Wrong answer0/53ms3528 KiB
13Wrong answer0/63ms3676 KiB
14Wrong answer0/63ms3864 KiB
15Wrong answer0/73ms3968 KiB
16Wrong answer0/73ms3856 KiB
17Wrong answer0/73ms3980 KiB