QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#569093 | #9320. Find the Easiest Problem | Woufan | WA | 0ms | 3636kb | C++20 | 951b | 2024-09-16 20:27:18 | 2024-09-16 20:27:18 |
Judging History
answer
//
// Created by 2 on 2024/9/15/015.
//
#include <bits/stdc++.h>
using namespace std;
#define all(a) a.begin(), a.end()
#define pb push_back
#define eb emplace_back
#define IOS ios::sync_with_stdio(false); cin.tie(0)
#define endl '\n'
using pii = pair<int, int>;
using ll = long long;
const int N = 2e5 + 10;
const int mod = 1e9;
const ll MAX = 1e18;
void solve() {
int n;
cin >> n;
string s, y;
char x;
set<string> st[26];
for (int i = 0; i < n; ++i) {
cin >> s >> x >> y;
if (y == "accepted")
st[x - 'A'].insert(s);
}
int mx = 0;
for (const auto &item: st)
mx = max(mx, (int)size(item));
for (int i = 0; i < 26; ++i)
if (st[i].size() == mx) {
cout << i + 'A' << endl;
return;
}
}
int main() {
IOS;
int t = 1;
cin >> t;
while (t--)
solve();
return 0;
}
詳細信息
Test #1:
score: 0
Wrong Answer
time: 0ms
memory: 3636kb
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:
65 65
result:
wrong answer 1st lines differ - expected: 'A', found: '65'