Submission #470566

# Submission time Handle Problem Language Result Execution time Memory
470566 2021-09-04T09:43:28 Z Karabasan Utrka (COCI14_utrka) C++17
0 / 80
91 ms 10260 KB
#include <bits/stdc++.h>
#define fast ios_base::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL);
#define forcin for(int i=1;i<=n;i++) scanf("%d",&dizi[i]);
#define forcout for(int i=0;i<n;i++) printf("%d ",dizi[i]);
#define ll long long

using namespace std;
int n,t,cevap;
string s[100005];
map <string,int> mp;
int main()
{
    scanf("%d",&n);
    for(int i=0;i<2*n-1;i++)
        cin>>s[i];
    for(int i=0;i<2*n-1;i++)
        mp[s[i]]++; 
    for(int i=0;i<2*n;i++)
    {
           if (mp[s[i]]%2==1)
               {cout<<s[i];
                return 0;}
    }
        
        
       

    return 0;
}

/*
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠀⠀⣠⣶⡾⠏⠉⠙⠳⢦⡀⠀⠀⠀⢠⠞⠉⠙⠲⡀⠀
⠀⠀⠀⣴⠿⠏⠀⠀⠀⠀ ⠀⠀⢳⡀  ⡏⠀⠀⠀⠀⠀⢷
⠀⠀⢠⣟⣋⡀⢀⣀⣀⡀⠀⣀⡀⣧⠀⢸⠀⠀⠀⠀⠀ ⡇
⠀⠀⢸⣯⡭⠁⠸⣛⣟⠆⡴⣻⡲⣿⠀⣸⠀⠀Ez⠀ ⡇
⠀⠀⣟⣿⡭⠀⠀⠀⠀⠀⢱⠀ ⠀⣿⠀⢹⠀⠀⠀⠀⠀ ⡇
⠀⠀⠙⢿⣯⠄⠀⠀⠀⢀⡀⠀⠀⡿⠀⠀⡇⠀⠀⠀⠀⡼
⠀⠀⠀⠀⠹⣶⠆⠀⠀⠀⠀⠀⡴⠃⠀⠀⠘⠤⣄⣠⠞⠀
⠀⠀⠀⠀⠀⢸⣷⡦⢤⡤⢤⣞⣁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠀⠀⢀⣤⣴⣿⣏⠁⠀⠀⠸⣏⢯⣷⣖⣦⡀⠀⠀⠀⠀⠀⠀
⢀⣾⣽⣿⣿⣿⣿⠛⢲⣶⣾⢉⡷⣿⣿⠵⣿⠀⠀⠀⠀⠀⠀
⣼⣿⠍⠉⣿⡭⠉⠙⢺⣇⣼⡏⠀⠀⠀⣄⢸⠀⠀⠀⠀⠀⠀
⣿⣿⣧⣀⣿.........⣀⣰⣏⣘⣆⣀⠀⠀


░██████╗░█████╗░██╗████████╗░█████╗░███╗░░░███╗░█████╗░
██╔════╝██╔══██╗██║╚══██╔══╝██╔══██╗████╗░████║██╔══██╗
╚█████╗░███████║██║░░░██║░░░███████║██╔████╔██║███████║  SENSEI
░╚═══██╗██╔══██║██║░░░██║░░░██╔══██║██║╚██╔╝██║██╔══██║
██████╔╝██║░░██║██║░░░██║░░░██║░░██║██║░╚═╝░██║██║░░██║
╚═════╝░╚═╝░░╚═╝╚═╝░░░╚═╝░░░╚═╝░░╚═╝╚═╝░░░░░╚═╝╚═╝░░╚═╝



*/

Compilation message

utrka.cpp: In function 'int main()':
utrka.cpp:13:10: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
   13 |     scanf("%d",&n);
      |     ~~~~~^~~~~~~~~
# Verdict Execution time Memory Grader output
1 Correct 2 ms 3404 KB Output is correct
2 Correct 2 ms 3432 KB Output is correct
3 Correct 3 ms 3404 KB Output is correct
4 Correct 4 ms 3532 KB Output is correct
5 Correct 3 ms 3532 KB Output is correct
6 Correct 91 ms 9648 KB Output is correct
7 Runtime error 46 ms 10260 KB Execution killed with signal 11
8 Halted 0 ms 0 KB -