CCF 【201412-1】门禁系统
程序员文章站
2024-02-23 21:48:16
...
#include<iostream>
using namespace std;
int str[1001];
int main()
{
int n,i,m;
cin>>n;
for(i=0;i<n;i++)
{
cin>>m;
str[m]++;
cout<<str[m]<<" ";//关键是str[m], not is str[i]
}
return 0;
}