#include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
int n;
cin >> n;
set<string> S;
for (int i = 0; i < n; i++) {
string s;
cin >> s;
S.insert(s);
}
ll m;
cin >> m;
vector<pair<string, ll>> all(m);
ll sum = 0;
for (int i = 0; i < m; i++) {
cin >> all[i].first >> all[i].second;
sum += all[i].second;
}
vector<string> res;
for (int i = 0; i < m; i++) {
if (all[i].second * m > sum && !S.count(all[i].first)) {
res.push_back(all[i].first);
}
}
if (res.empty()) {
cout << "Bing Mei You" << "\n";
} else {
sort(res.begin(), res.end());
for (int i = 0; i < res.size(); i++) {
cout << res[i] << "\n"[i == res.size() - 1];
}
}
return 0;
}