# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
1128091 | nuutsnoynton | 평균 (COCI14_prosjek) | C++17 | 1 ms | 328 KiB |
#include<bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
ll n, m, s, r, x, y, i, j, ans, t, p;
cin >> n;
ll a[n + 2];
for (i = 1; i <= n; i ++) {
cin >> a[i];
}
s =0;
for (i = 1; i <= n; i ++) {
p = a[i] * i - s;
s += p;
cout << p << " ";
}
cout << endl;
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |