Submission #314743

#TimeUsernameProblemLanguageResultExecution timeMemory
314743aaae4hujikwe4rfjioProsjek (COCI18_prosjek)C++14
50 / 50
1 ms384 KiB
#include <bits/stdc++.h> #define ll long long #define MAXN 0 using namespace std; int main(){ ios_base::sync_with_stdio(false); cin.tie(NULL); multiset<double> m; int n, aux; cin >> n; for(int i = 0; i < n; i++) cin >> aux, m.insert(aux); for(int i = 0; i < n-1; i++){ double a = *m.begin(); m.erase(m.begin()); double b = *m.begin(); m.erase(m.begin()); m.insert((a+b)/2); } cout << *m.begin(); return 0; }
#Verdict Execution timeMemoryGrader output
Fetching results...