Run ID 作者 问题 语言 测评结果 时间 内存 代码长度 提交时间
71799 sh25_ganzy 直方图 C++ 编译错误 0 MS 0 KB 326 2025-10-29 13:37:58

Tests(0/0):


#include<bits/stdc++.h> using namespace std; int main(){ int n; cin>>n; float num[n],max=0; int cnt[int(max)+1]={0}; for(int i=0;i<n;i++){ cin>>num[i]; max=max(max,num[i]); cnt[num[i]]++; } for(int i=0;i<=max;i++){ cout<<cnt[i]; } return 0; }


测评信息: