# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
919130 | 2024-01-31T11:08:15 Z | TIN | Utrka (COCI14_utrka) | C++17 | 70 ms | 11304 KB |
#include <bits/stdc++.h> using namespace std; #define FNAME "test" const int N = 1e5 + 5; int n; string s[N], t[N]; void Task() { ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0); cout << fixed << setprecision(9); if (fopen(FNAME".inp","r")) { freopen(FNAME".inp","r",stdin); freopen(FNAME".out","w",stdout); } } void Solve() { //Your Code cin >> n; for (int i = 1; i <= n; i++) { cin >> s[i]; } sort(s + 1, s + n + 1); for (int i = 1; i < n; i++) { cin >> t[i]; } sort(t + 1, t + n); t[n] = ""; for (int i = 1; i <= n; i++) { if (s[i] != t[i]) { cout << s[i]; return; } } } int main() { Task(); Solve(); cerr << "\nTime run: " << 1000*clock()/CLOCKS_PER_SEC << "ms"; return 37^37; }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 2 ms | 6692 KB | Output is correct |
2 | Correct | 3 ms | 6488 KB | Output is correct |
3 | Correct | 2 ms | 6744 KB | Output is correct |
4 | Correct | 3 ms | 6744 KB | Output is correct |
5 | Correct | 3 ms | 6744 KB | Output is correct |
6 | Correct | 38 ms | 8812 KB | Output is correct |
7 | Correct | 52 ms | 10064 KB | Output is correct |
8 | Correct | 63 ms | 10828 KB | Output is correct |
9 | Correct | 70 ms | 11304 KB | Output is correct |
10 | Correct | 68 ms | 11092 KB | Output is correct |