QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#567775#9320. Find the Easiest ProblemLoxilante#RE 0ms3796kbC++141.3kb2024-09-16 13:52:232024-09-16 13:52:23

Judging History

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

  • [2024-09-16 13:52:23]
  • 评测
  • 测评结果:RE
  • 用时:0ms
  • 内存:3796kb
  • [2024-09-16 13:52:23]
  • 提交

answer

#define F_C
#include <bits/stdc++.h>
#define rep(i, l, r) for(int i = l; i < r; i++)
#define hrp(i, l, r) for(int i = l; i <= r; i++)
#define rev(i, r, l) for(int i = r; i >= l; i--)
#define int ll
using namespace std;
typedef long long ll;
template<typename tn = int> tn next(void) { tn k; cin>>k; return k; }
#ifndef LOCAL
#define D(...) 0
#endif
signed main(void)
{
    #ifdef LOCAL
//	freopen("C:\\Users\\Loxil\\Desktop\\IN.txt", "r", stdin);
//	freopen("C:\\Users\\Loxil\\Desktop\\OUT.txt", "w", stdout);
    #endif
    
    ios::sync_with_stdio(false);
    cin.tie(0);
    
    int T = next();
    while(T--)
    {
        int n = next();
        set<string> st[30];
        rep(i, 0, n)
        {
            string team, problem, stat;
            cin>>team>>problem>>stat;
            team = team.substr(4);

            if (stat[0] == 'a') st[problem[0]-'A'].insert(team);
        }

        int maxx = 0, prob;
        rep(i, 0, 26) if (st[i].size() > maxx) maxx = st[i].size(), prob = i;

        cout<<(char)(prob+'A')<<endl;
    }
    
    return 0;
}
/*
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
 */

詳細信息

Test #1:

score: 100
Accepted
time: 0ms
memory: 3796kb

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:

A
A

result:

ok 2 lines

Test #2:

score: -100
Runtime Error

input:

1000
44
WaiooyIXa O accepted
WaiooyIXa P accepted
ZYYsNWag P accepted
DPIawQg D rejected
IzPdjnM Z rejected
Ra D rejected
kwQyGxLo I rejected
DPIawQg L accepted
kwQyGxLo I accepted
mmWxDuADCB D rejected
PXwVAOgwiz P rejected
ZYYsNWag U accepted
IzPdjnM Z accepted
TgBNO P rejected
kwQyGxLo J accepted...

output:


result: