# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
268328 | mayhoubsaleh | Prosjek (COCI14_prosjek) | C++14 | 1 ms | 396 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
#define ll long long
#define pb push_back
#define IOS ios_base::sync_with_stdio(false);cin.tie(0);cout.tie(0);
using namespace std;
const ll maxn=5e5+100;
const ll inf=1e9+10;
ll n;
ll a[maxn];
int main()
{
IOS
cin>>n;
for(ll i=0;i<n;i++)cin>>a[i];
for(ll i=0;i<n;i++){
a[i]=a[i]*(i+1);
if(i)cout<<a[i]-a[i-1]<<' ';
else cout<<a[i]<<' ';
}
cout<<endl;
return 0;
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |