| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 142181 | 李茗宇 | 18统计成绩 | C++ | Accepted | 1 MS | 276 KB | 602 | 2025-12-31 19:46:15 |
#include<iostream> // cin\cout\endl #include<cstdio> //scanf()\printf() #include<cstring> // strcpy()\strcat()\strcmp()\strlen()\memset() #include<cmath> //sqrt()\pow()\abs()\ceil()\floor()\max()\min() using namespace std; int main(){ int n,z=0,max=-1,min=101; double p=0; cin>>n; int s[n]; for(int i=1;i<=n;i++){ cin>>s[i]; z+=s[i]; if(s[i]>max){ max=s[i]; } if(min>s[i]){ min=s[i]; } } p=z*1.0/n; printf("%d %.2lf %d %d",z,p,max,min); return 0; }