# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
87819 | AntonioDaki | Prosjek (COCI18_prosjek) | C++14 | 3 ms | 820 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>
using namespace std;
int main()
{
ios::sync_with_stdio(0);
cin.tie(0);
float n, x[22], m = 0;
cin >> n;
cin >> x[0];
for(int i = 1; i < n; ++i){
cin >> x[i];
x[i] = (x[i] + x[i - 1]) / 2;
if(x[i] > m) m = x[i];
}
cout << m;
return 0;
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |