QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#589570#9320. Find the Easiest Problemtjrac6022203192WA 0ms3808kbC++14607b2024-09-25 18:36:372024-09-25 18:36:38

Judging History

你现在查看的是最新测评结果

  • [2024-09-25 18:36:38]
  • 评测
  • 测评结果:WA
  • 用时:0ms
  • 内存:3808kb
  • [2024-09-25 18:36:37]
  • 提交

answer

#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
const int N=1e3+10; 
const ll mod=998244353;
ll a[N];
ll f[N];
void solve()
{
  ll n;
  cin>>n;
  map<string,set<string>>mp;
  for(int i=1;i<=n;i++)
  {
        string a,b,c;
        if(c[0]=='a')
        {
            mp[b].insert(a);
        }
  }
  int maxx=0;
  string ans;
  for(auto it:mp)
  {
    if(it.second.size()>maxx)
    {
        maxx=it.second.size();
        ans=it.first;
    }
  }
  cout<<ans<<"\n";
}

int main()
{
    int t=1;
    // cin>>t;
    while(t--) solve();
    return 0;
}

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 0
Wrong Answer
time: 0ms
memory: 3808kb

input:

2
5
teamA A accepted
teamB B rejected
teamC A accepted
teamB B accepted
teamD C accepted
4
teamA A rejected
teamB A accepted
teamC B accepted
teamC B accepted

output:



result:

wrong answer 1st lines differ - expected: 'A', found: ''