Submission #17500

# Submission time Handle Problem Language Result Execution time Memory
17500 2015-12-22T02:44:08 Z kdh9949 Utrka (COCI14_utrka) C++
80 / 80
502 ms 12812 KB
#include <iostream>
#include <map>
#include <string>
using namespace std;

int n;
string str;
map<string, int> mp;

int main(){
    cin >> n;
    for(int i = 0; i < n; i++){
        cin >> str;
        mp[str]++;
    }
    for(int i = 0; i < n - 1; i++){
        cin >> str;
        mp[str]--;
        if(mp[str] == 0) mp.erase(str);
    }
    cout << mp.begin()->first;
}
# Verdict Execution time Memory Grader output
1 Correct 0 ms 1724 KB Output is correct
2 Correct 0 ms 1724 KB Output is correct
3 Correct 0 ms 1724 KB Output is correct
4 Correct 3 ms 1724 KB Output is correct
5 Correct 0 ms 1724 KB Output is correct
6 Correct 215 ms 7268 KB Output is correct
7 Correct 359 ms 9908 KB Output is correct
8 Correct 436 ms 11756 KB Output is correct
9 Correct 463 ms 12812 KB Output is correct
10 Correct 502 ms 12812 KB Output is correct