Run ID | 作者 | 问题 | 语言 | 测评结果 | 分数 | 时间 | 内存 | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|---|
101508 | 林泽豪 | 统计各数据个数 | C++ | 解答错误 | 0 | 11 MS | 244 KB | 311 | 2023-09-09 09:56:14 |
#include<iostream> #include<cstdio> using namespace std; int b[21]; int main(){ //freopen("statistics.in","r",stdin); //freopen("statistics.out","w",stdout); int a,p=1; while(cin>>a){ b[a]++; p++; } cout<<p<<endl; for(int i=0;i<=20;i++){ cout<<b[i]<<' '; } }