| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 63581 | 谌俊林 | 18高于平均分的学生数量 | C++ | Accepted | 2 MS | 280 KB | 271 | 2024-01-18 15:03:55 |
#include<iostream> #include<cstdio> using namespace std; int main(){ int i,n,tot=0,t,c =0; cin>>n; int a[n]; for (i=0;i<n;i++){ cin>>a[i]; tot+=a[i]; } t=tot*1.0/n; for (i=0;i<n;i++){ if(a[i]>t) c++; } cout<<c; return 0; }