文章
37
粉丝
168
获赞
28
访问
309.2k
#include <bits/stdc++.h>
using namespace std;
int main()
{
int N,M;
while(cin>>N>>M){
map<int,int> m;
int a[N];
for(int i=0; i<N; i++)
cin>>a[i];
for(int i=0; i<N; i++)
m[a[i]]++;
for(int i=0; i<N; i++){
if(m[a[i]]>=2) cout<<m[a[i]]-1<<endl;
else cout<<"BeiJu"<<endl;
}
}
}
登录后发布评论
暂无评论,来抢沙发