# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
207437 | ThegeekKnight16 | Prosjek (COCI18_prosjek) | C++14 | 6 ms | 376 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<float> v;
int main()
{
ios_base::sync_with_stdio(false);
cin.tie(NULL);
int N;
cin >> N;
for (int i = 0; i < N; i++)
{
float Numb;
cin >> Numb;
v.push_back(Numb);
}
sort(v.begin(),v.end());
float Media = 0.0;
Media = (v[0] + v[1]) / 2;
for (int i = 2; i < N; i++)
{
Media = (Media + v[i]) / 2;
}
cout << Media;
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |