0
1
mirror of https://git.sb/baoshuo/OI-codes.git synced 2024-11-30 16:56:27 +00:00

B - Who is missing?

https://atcoder.jp/contests/abc236/submissions/28730078
This commit is contained in:
Baoshuo Ren 2022-01-23 20:08:03 +08:00
parent cb4719c0c9
commit 2cb9668697
Signed by: baoshuo
GPG Key ID: 70F90A673FB1AB68

24
AtCoder/ABC236/B/B.cpp Normal file
View File

@ -0,0 +1,24 @@
#include <iostream>
#include <map>
using std::cin;
using std::cout;
using std::endl;
int n, a;
std::map<int, int> map;
int main() {
cin >> n;
for (int i = 1; i < n * 4; i++) {
cin >> a;
map[a]++;
}
for (int i = 1; i <= n; i++) {
if (map[i] == 3) {
cout << i << endl;
return 0;
}
}
return 0;
}