Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <bits/stdc++.h>
- using namespace std;
- const int N = 1e5 + 3;
- int cnt[N];
- int main(){
- int n;
- cin >> n;
- for (int i = 1; i <= 4 * n - 1; i++) {
- int x;
- cin >> x;
- cnt[x]++;
- }
- for (int i = 1; i <= n; i++) {
- if (cnt[i] == 3) {
- cout << i << endl;
- return 0;
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement