Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
148512 张晓冉 18统计成绩 C++ Compile Error 0 MS 0 KB 489 2026-02-23 15:33:44

Tests(0/0):


Code:

#include<bits/stdc++.h> using namespace std; int main(){ int n; cin>>n; int cj[100] = {}; double z=0,p=0,zd=0,zx=111111,s = 0; for(int i = 1;i <= n;i++){ cin>>cj[i]; z += cj[i]; } for(int i = 1;i <= n;i++){ if(cj[i]>zd){ zd = cj[i]; }if(cj[i]<zx) zx = cj[i]; } cout<<z<<" "; printf("%.2f\n",z/n); cout<<" "; cout<zd<<" "; cout<<zx; return 0; }


Run Info:

Main.cc: In function 'int main()':
Main.cc:21:14: error: invalid operands of types 'double' and 'const char [2]' to binary 'operator<<'
     cout