# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
717380 | 2023-04-01T22:02:57 Z | vjudge1 | Table Tennis (info1cup20_tabletennis) | C++17 | 1 ms | 468 KB |
#include <bits/stdc++.h> using namespace std; #define int long long const int mxN = 2e5 + 7; bool in[mxN]; int arr[mxN]; int32_t main() { ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0); int n, k; cin >> n >> k; for (int i = 0; i < n + k; ++i) { cin >> arr[i]; in[arr[i]] = true; } for (int i = 0; i < k + 2; ++i) { for (int j = n + k - 1; j >= n - 1 && j > i; --j) { int sum = arr[i] + arr[j]; vector<int> nums; for (int l = 0; l < n + k; ++l) { if (sum - arr[l] >= 0 && in[sum - arr[l]]) { nums.push_back(arr[l]); } } if (nums.size() >= n) { for (int l = 0; l < n; ++l) { cout << nums[l] << ' '; } cout << "\n"; exit(0); } } } } // 1 2 1 2 3
Compilation message
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 468 KB | Execution killed with signal 11 |
2 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 456 KB | Execution killed with signal 11 |
2 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 468 KB | Execution killed with signal 11 |
2 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 468 KB | Execution killed with signal 11 |
2 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 468 KB | Execution killed with signal 11 |
2 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 468 KB | Execution killed with signal 11 |
2 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 468 KB | Execution killed with signal 11 |
2 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 468 KB | Execution killed with signal 11 |
2 | Halted | 0 ms | 0 KB | - |