#include <iostream>
#include <vector>
#include <map>
using namespace std;
#define maxn 100005
int n;
vector<string> nm;
map<string,bool> seen;
int main() {
cin >> n;
for (int i = 0; i < n; i++) {
string s; cin >> s;
nm.push_back(s); seen[s] = false;
}
for (int i = 0; i < n-1; i++) {
string s; cin >> s;
seen[s] = true;
}
for (string s : nm) {
if (!seen[s]) cout << s << endl;
}
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
1 ms |
204 KB |
Output is correct |
2 |
Incorrect |
1 ms |
204 KB |
Output isn't correct |
3 |
Halted |
0 ms |
0 KB |
- |