# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
444157 | 2021-07-13T07:38:22 Z | 8e7 | The Collection Game (BOI21_swaps) | C++17 | 71 ms | 448 KB |
//Challenge: Accepted #include "swaps.h" #include <iostream> #include <algorithm> #include <vector> #include <utility> #include <queue> #include <set> #include <ext/pb_ds/assoc_container.hpp> #include <ext/pb_ds/tree_policy.hpp> using namespace std; //using namespace __gnu_pbds; void debug() {cout << endl;} template<class T, class ... U> void debug(T a, U ... b) {cout << a << " ", debug(b ...);} template<class T> void pary(T l, T r) { while (l != r) cout << *l << " ", l++; cout << endl; } #define ll long long #define maxn 100005 #define pii pair<int, int> #define ff first #define ss second #define io ios_base::sync_with_stdio(0); void solve(int N, int V) { vector<int> ret; for (int i = 0;i < N;i++) ret.push_back(i + 1); for (int ti = 0;ti < N;ti++) { vector<int> v; for (int i = ti % 2;i + 1 < N;i += 2) schedule(ret[i], ret[i + 1]); v = visit(); for (int i = ti % 2, j = 0;j < v.size();i += 2, j++) { if (v[j] == 0) { swap(ret[i], ret[i + 1]); } } } answer(ret); }
Compilation message
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 200 KB | Correct |
2 | Correct | 3 ms | 200 KB | Correct |
3 | Correct | 15 ms | 200 KB | Correct |
4 | Correct | 51 ms | 376 KB | Correct |
5 | Correct | 55 ms | 292 KB | Correct |
6 | Correct | 51 ms | 296 KB | Correct |
7 | Correct | 56 ms | 356 KB | Correct |
8 | Correct | 71 ms | 296 KB | Correct |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 200 KB | Correct |
2 | Correct | 3 ms | 200 KB | Correct |
3 | Correct | 15 ms | 200 KB | Correct |
4 | Correct | 57 ms | 292 KB | Correct |
5 | Correct | 53 ms | 292 KB | Correct |
6 | Correct | 54 ms | 296 KB | Correct |
7 | Correct | 50 ms | 296 KB | Correct |
8 | Correct | 64 ms | 296 KB | Correct |
9 | Correct | 67 ms | 292 KB | Correct |
10 | Correct | 52 ms | 360 KB | Correct |
11 | Correct | 49 ms | 420 KB | Correct |
12 | Correct | 53 ms | 448 KB | Correct |
13 | Correct | 68 ms | 296 KB | Correct |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 200 KB | Correct |
2 | Correct | 4 ms | 200 KB | Correct |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 200 KB | Correct |
2 | Correct | 4 ms | 200 KB | Correct |
3 | Correct | 1 ms | 200 KB | Correct |
4 | Correct | 4 ms | 200 KB | Correct |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 200 KB | Correct |
2 | Correct | 3 ms | 200 KB | Correct |
3 | Correct | 17 ms | 200 KB | Correct |
4 | Correct | 55 ms | 296 KB | Correct |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 200 KB | Correct |
2 | Correct | 3 ms | 200 KB | Correct |
3 | Correct | 17 ms | 200 KB | Correct |
4 | Correct | 55 ms | 296 KB | Correct |
5 | Correct | 1 ms | 200 KB | Correct |
6 | Correct | 5 ms | 200 KB | Correct |
7 | Correct | 15 ms | 200 KB | Correct |
8 | Correct | 58 ms | 308 KB | Correct |
9 | Correct | 53 ms | 300 KB | Correct |
10 | Correct | 69 ms | 296 KB | Correct |
11 | Correct | 53 ms | 296 KB | Correct |
12 | Correct | 53 ms | 292 KB | Correct |
13 | Correct | 1 ms | 200 KB | Correct |
14 | Correct | 5 ms | 200 KB | Correct |
15 | Correct | 16 ms | 200 KB | Correct |
16 | Correct | 59 ms | 396 KB | Correct |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 0 ms | 200 KB | Correct |
2 | Correct | 4 ms | 200 KB | Correct |
3 | Correct | 15 ms | 200 KB | Correct |
4 | Correct | 69 ms | 296 KB | Correct |
5 | Correct | 53 ms | 292 KB | Correct |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 0 ms | 200 KB | Correct |
2 | Correct | 4 ms | 200 KB | Correct |
3 | Correct | 15 ms | 200 KB | Correct |
4 | Correct | 69 ms | 296 KB | Correct |
5 | Correct | 53 ms | 292 KB | Correct |
6 | Correct | 1 ms | 200 KB | Correct |
7 | Correct | 3 ms | 200 KB | Correct |
8 | Correct | 15 ms | 200 KB | Correct |
9 | Correct | 71 ms | 320 KB | Correct |
10 | Correct | 62 ms | 308 KB | Correct |
11 | Correct | 50 ms | 300 KB | Correct |
12 | Correct | 53 ms | 296 KB | Correct |
13 | Correct | 68 ms | 296 KB | Correct |
14 | Correct | 53 ms | 376 KB | Correct |
15 | Correct | 66 ms | 296 KB | Correct |
16 | Correct | 60 ms | 292 KB | Correct |
17 | Correct | 63 ms | 292 KB | Correct |
18 | Correct | 50 ms | 292 KB | Correct |
19 | Correct | 1 ms | 200 KB | Correct |
20 | Correct | 4 ms | 200 KB | Correct |
21 | Correct | 16 ms | 200 KB | Correct |
22 | Correct | 55 ms | 296 KB | Correct |
23 | Correct | 54 ms | 280 KB | Correct |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 200 KB | Correct |
2 | Correct | 3 ms | 200 KB | Correct |
3 | Correct | 14 ms | 200 KB | Correct |
4 | Correct | 57 ms | 312 KB | Correct |
5 | Correct | 51 ms | 292 KB | Correct |
6 | Runtime error | 11 ms | 280 KB | Execution killed with signal 13 |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 200 KB | Correct |
2 | Correct | 3 ms | 200 KB | Correct |
3 | Correct | 14 ms | 200 KB | Correct |
4 | Correct | 57 ms | 312 KB | Correct |
5 | Correct | 51 ms | 292 KB | Correct |
6 | Runtime error | 11 ms | 280 KB | Execution killed with signal 13 |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 200 KB | Correct |
2 | Correct | 3 ms | 200 KB | Correct |
3 | Correct | 15 ms | 200 KB | Correct |
4 | Correct | 50 ms | 296 KB | Correct |
5 | Correct | 54 ms | 280 KB | Correct |
6 | Runtime error | 11 ms | 280 KB | Execution killed with signal 13 |
7 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 200 KB | Correct |
2 | Correct | 3 ms | 200 KB | Correct |
3 | Correct | 15 ms | 200 KB | Correct |
4 | Correct | 50 ms | 296 KB | Correct |
5 | Correct | 54 ms | 280 KB | Correct |
6 | Runtime error | 11 ms | 280 KB | Execution killed with signal 13 |
7 | Halted | 0 ms | 0 KB | - |