제출 #141151

#제출 시각아이디문제언어결과실행 시간메모리
141151Breno_XD마라톤 경주 (COCI14_utrka)C++14
0 / 80
2 ms376 KiB
#include <bits/stdc++.h>
using namespace std;

int n;
map<string, int> mapa;

int main(){

    ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0);

    scanf("%d", &n);

    for(int i=1; i<=n; i++){
        string s;
        cin >> s;
        mapa[s]++;
    }

    for(int i=1; i<n; i++){
        string s;
        cin >> s;
        mapa[s]--;
    }

    for(map<string,int>::iterator it = mapa.begin(); it!=mapa.end(); it++){

        if(it->second == 1){
            cout << it->first << "\n";
            break;
        }

    }

    return 0;
}

컴파일 시 표준 에러 (stderr) 메시지

utrka.cpp: In function 'int main()':
utrka.cpp:11:10: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
     scanf("%d", &n);
     ~~~~~^~~~~~~~~~
#Verdict Execution timeMemoryGrader output
Fetching results...