更新时间:2022-08-13 08:45:14
题目链接:http://codeforces.com/contest/554/problem/B
#include <iostream>
#include <string>
#include <cmath>
using namespace std;
int main()
{
int ans=0,m;
while(cin>>m)
{
string s[105];
for(int i=0; i<m; i++)
cin>>s[i];
for(int i=0; i<m; i++)
{
int sum=0;
for(int j=0; j<m; j++)
if(s[i] == s[j])
sum++;
ans=max(ans,sum);
}
cout<<ans<<endl;
}
return 0;
}
Codeforces Round #409 (rated, Div. 2, based on VK Cup 2017 Round 2)(A.思维题,B.思维题)
Codeforces Round #326 (Div. 2) B. Pasha and Phone C. Duff and Weight Lifting
接上一篇 580 B. Kefa and Company [ Codeforces Round #321 (Div. 2)]
Codeforces Round #327 (Div. 2) B. Rebranding C. Median Smoothing
codeforces 578 B. Finding Team Member( Codeforces Round #320 (Div. 2) )
Codeforces 584 B. Kolya and Tanya (Codeforces Round #324 (Div. 2))