6034 | 2023-10-28 00:05:25 | xxx | Könyvkupac | cpp14 | Accepted 100/100 | 3ms | 3156 KiB |
// @check-accepted: examples no-limits
#include <iostream>
static void move(int amount, int from, int to) {
std::cout << amount << ' ' << from << ' ' << to << '\n';
}
int main() {
int n;
std::cin >> n;
for (int i = 0; i < (n + 1) / 2; ++i) {
move(1, 0, 1);
}
move(n / 2, 0, 1);
for (int i = 0; i < n / 2; ++i) {
move(1, 1, 0);
}
move(n / 2, 0, 1);
}
Subtask | Sum | Test | Verdict | Time | Memory | ||
---|---|---|---|---|---|---|---|
subtask1 | 0/0 | ||||||
1 | Accepted | 3ms | 1876 KiB | ||||
2 | Accepted | 3ms | 2116 KiB | ||||
subtask2 | 100/100 | ||||||
3 | Accepted | 3ms | 2364 KiB | ||||
4 | Accepted | 3ms | 2576 KiB | ||||
5 | Accepted | 3ms | 2792 KiB | ||||
6 | Accepted | 3ms | 2944 KiB | ||||
7 | Accepted | 3ms | 3024 KiB | ||||
8 | Accepted | 3ms | 3156 KiB |