Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
120590 葛屹阳 计算平均数 C++ Accepted 1 MS 276 KB 275 2025-05-30 19:59:10

Tests(10/10):


Code:

#include<iostream> using namespace std; int main() { int a[11]; float he=0; for(int i=1;i<=5;i++) { cin>>a[i]; he=he+a[i]; } printf("%.2f\n",he/5); for(int i=1;i<=5;i++) { if(a[i]>he/5) { cout<<a[i]<<" "; } } return 0; }