Submission #1171494

#TimeUsernameProblemLanguageResultExecution timeMemory
1171494NomioUtrka (COCI14_utrka)C++20
80 / 80
94 ms16712 KiB
#include<bits/stdc++.h>
using namespace std;
int main() {
	ios::sync_with_stdio(0);
	cin.tie(0);
	int n;
	cin >> n;
	string s[n * 2];
	map<string, int> m;
	for(int i = 0; i < n * 2 - 1; i++) {
		cin >> s[i];
		m[s[i]]++;
	}
	for(int i = 0; i < n * 2 - 1; i++) {
		if(m[s[i]] % 2 == 1) {
			cout << s[i] << '\n';
			return 0;
		}
	}
	return 0;
}
#Verdict Execution timeMemoryGrader output
Fetching results...