# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
603287 | LucaGreg | Prosjek (COCI18_prosjek) | C++17 | 1 ms | 304 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;
vector<int> v;
int main()
{
int n; scanf("%d", &n);
for(int i=0;i<n;i++){
int vi; scanf("%d", &vi);
v.push_back(vi);
}
sort(v.begin(), v.end());
double m = v[0];
for(int i=1;i<=n-1;i++){
m = (m + v[i])/2;
}
printf("%f", m);
return 0;
}
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |