Submission #392372

#TimeUsernameProblemLanguageResultExecution timeMemory
392372GammaProsjek (COCI18_prosjek)C++14
50 / 50
1 ms208 KiB
#include <bits/stdc++.h> using namespace std; int n; double a[21]; int main() { cin >> n; for(int i = 0; i < n; i++) { cin >> a[i]; } sort(a, a + n); for(int i = 1; i < n; i++) { //cout << a[i] << ' '; a[i] = (a[i] + a[i - 1]) / 2.0; } cout << a[n - 1] << '\n'; }
#Verdict Execution timeMemoryGrader output
Fetching results...