提交时间:2021-12-11 15:09:31
运行 ID: 27289
#include<bits/stdc++.h> using namespace std; double n,a[110],ans,d; int main(){ cin>>n; for(int i=1;i<=n;i++){ cin>>a[i]; ans+=a[i]; } ans/=n; printf("%.1lf\n",ans); for(int i=1;i<=n;i++){ if(a[i]>ans){ cout<<i<<":"<<a[i]<<" "; } } return 0; }