Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
129142 周民苡 14慈善募捐 C++ Accepted 2 MS 272 KB 230 2025-08-22 12:05:51

Tests(10/10):


Code:

#include<bits/stdc++.h> #include<cstdio> using namespace std; int main() { double n,p,s=0; int i; for(i=1;i<=1000;i++){ cin>>n; s+=n; if(s>100000)break; } p=s/i; printf("%d %.2lf\n",i,p); return 0; }