QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#593942 | #6677. Puzzle: Sashigane | Proaes | AC ✓ | 2ms | 7168kb | C++20 | 6.8kb | 2024-09-27 17:21:06 | 2024-09-27 17:21:07 |
Judging History
answer
/**
* title: l.cpp
* author: Proaes Meluam
* created: 2024-09-27 15:09:35
**/
#include <bits/stdc++.h>
#ifdef LOCAL
#include "algo/debug.h"
#else
#define debug(...) 42
#endif
using namespace std;
using ll = long long;
using ull = unsigned long long;
const double pi = acos(-1);
const double E = exp(1);
constexpr ll mod = 1e9 + 7;
constexpr int inf = 0x3f3f3f3f;
// constexpr ll inf = 0x3f3f3f3f3f3f3f3f;
class dur {
public:
int l, r;
};
int main() {
cin.tie(nullptr)->sync_with_stdio(false);
int n, x, y;
cin >> n >> x >> y;
vector<tuple<int, int, int, int>> tl;
vector<vector<int>> g(n + 1, vector<int>(n + 1));
auto add = [&](int x, int y, int h, int w) {
tl.emplace_back(x, y, h, w);
g[x][y]++;
for (int i = 1; i <= h; ++ i) {
g[x + i][y]++;
}
for (int i = h; i <= -1; ++ i) {
g[x + i][y]++;
}
for (int i = 1; i <= w; ++ i) {
g[x][y + i]++;
}
for (int i = w; i <= -1; ++ i) {
g[x][y + i]++;
}
};
auto show = [&]() {
for (int i = 1; i <= n; ++ i) {
for (int j = 1; j <= n; ++ j) {
cout << g[i][j];
}
cout << "\n";
}
};
auto f = [&](dur row, dur col) {
if (x - row.l <= row.r - x) {
if (y - col.l <= col.r - y) {
return 1;
} else {
return 2;
}
} else {
if (y - col.l <= col.r - y) {
return 3;
} else {
return 4;
}
}
};
auto f2 = [&](dur row, dur col) {
if (x == row.l) {
if (y == col.l) {
// tl.emplace_back(row.r, col.r, -1, -1);
// cout << row.r << " " << col.r << " " << -1 << " " << -1 << "\n";
add(row.r, col.r, -1, -1);
} else {
// tl.emplace_back(row.r, col.l, -1, 1);
// cout << row.r << " " << col.l << " " << -1 << " " << 1 << "\n";
add(row.r, col.l, -1, 1);
}
} else {
if (y == col.l) {
// tl.emplace_back(row.l, col.r, 1, -1);
// cout << row.l << " " << col.r << " " << 1 << " " << -1 << "\n";
add(row.l, col.r, 1, -1);
} else {
// tl.emplace_back(row.l, col.l, 1, 1);
// cout << row.l << " " << col.l << " " << 1 << " " << 1 << "\n";
add(row.l, col.l, 1, 1);
}
}
};
if (n == 1) {
cout << "Yes" << "\n";
cout << 0 << "\n";
} else {
cout << "Yes" << "\n";
dur row, col;
row.l = 1, row.r = n;
col.l = 1, col.r = n;
int need = inf;
need = min(need, x - row.l);
need = min(need, row.r - x);
need = min(need, y - col.l);
need = min(need, col.r - y);
int h, w;
for (int i = 1; i <= need; ++ i) {
h = row.r - i - 1;
w = col.r - i;
// tl.emplace_back(i, i, h, w);
// cout << i << " " << i << " " << h << " " << w << "\n";
add(i, i, h, w);
h = -(row.r - i - 1);
w = -(col.r - i);
// tl.emplace_back(row.r, col.r, h, w);
// cout << row.r << " " << col.r << " " << h << " " << w << "\n";
add(row.r, col.r, h, w);
row.l ++;
row.r --;
col.l ++;
col.r --;
}
auto run = [&]() {
int flag = f(row, col);
if (flag == 1) {
while (1) {
if (x == row.r || y == col.r) break;
int h = -(row.r - row.l);
int w = -(col.r - col.l);
// tl.emplace_back(row.r, col.r, h, w);
// cout << row.r << " " << col.r << " " << h << " " << w << "\n";
add(row.r, col.r, h, w);
row.r --;
col.r --;
}
} else if (flag == 2) {
while (1) {
if (x == row.r || y == col.l) break;
int h = -(row.r - row.l);
int w = (col.r - col.l);
// tl.emplace_back(row.r, col.l, h, w);
// cout << row.r << " " << col.l << " " << h << " " << w << "\n";
add(row.r, col.l, h, w);
row.r --;
col.l ++;
}
//
} else if (flag == 3) {
while (1) {
if (x == row.l || y == col.r) break;
int h = (row.r - row.l);
int w = -(col.r - col.l);
// tl.emplace_back(row.l, col.r, h, w);
// cout << row.l << " " << col.r << " " << h << " " << w << "\n";
add(row.l, col.r, h, w);
row.l ++;
col.r --;
}
//
} else if (flag == 4) {
while (1) {
if (x == row.l || y == col.l) break;
int h = (row.r - row.l);
int w = (col.r - col.l);
// tl.emplace_back(row.l, col.l, h, w);
// cout << row.l << " " << col.l << " " << h << " " << w << "\n";
add(row.l, col.l, h, w);
row.l ++;
col.l ++;
}
//
}
};
// int cur = 0;
while (1) {
if (row.r - row.l == 0 && col.r - col.l == 0) {
break;
} else if (row.r - row.l == 1 && col.r - col.l == 1) {
if (x != row.r || y != col.r) {
f2(row, col);
break;
}
if (x != row.r || y != col.l) {
f2(row, col);
break;
}
if (x != row.l || y != col.r) {
f2(row, col);
break;
}
if (x != row.l || y != col.l) {
f2(row, col);
break;
}
} else {
run();
// cur ++;
// if (cur == 2) break;
}
}
// cout << row.l << " " << row.r << "\n";
// cout << col.l << " " << col.r << "\n";
// show();
cout << (int)tl.size() << "\n";
for (auto [a, b, c, d] : tl) {
cout << a << " " << b << " " << c << " " << d << "\n";
}
// show();
}
}
这程序好像有点Bug,我给组数据试试?
詳細信息
Test #1:
score: 100
Accepted
time: 0ms
memory: 3568kb
input:
5 3 4
output:
Yes 4 1 1 3 4 5 5 -3 -4 4 2 -2 2 2 3 1 1
result:
ok Correct. (1 test case)
Test #2:
score: 0
Accepted
time: 0ms
memory: 3560kb
input:
1 1 1
output:
Yes 0
result:
ok Correct. (1 test case)
Test #3:
score: 0
Accepted
time: 0ms
memory: 3624kb
input:
3 2 3
output:
Yes 2 3 1 -2 2 1 2 1 1
result:
ok Correct. (1 test case)
Test #4:
score: 0
Accepted
time: 0ms
memory: 3624kb
input:
10 10 5
output:
Yes 9 1 10 9 -9 2 9 8 -8 3 8 7 -7 4 7 6 -6 5 6 5 -5 6 1 4 4 7 2 3 3 8 3 2 2 9 4 1 1
result:
ok Correct. (1 test case)
Test #5:
score: 0
Accepted
time: 0ms
memory: 3556kb
input:
10 5 7
output:
Yes 9 1 1 8 9 10 10 -8 -9 2 2 6 7 9 9 -6 -7 3 3 4 5 8 8 -4 -5 7 4 -3 3 6 5 -2 2 4 6 1 1
result:
ok Correct. (1 test case)
Test #6:
score: 0
Accepted
time: 0ms
memory: 3548kb
input:
10 9 2
output:
Yes 9 1 1 8 9 10 10 -8 -9 2 9 7 -7 3 8 6 -6 4 7 5 -5 5 6 4 -4 6 5 3 -3 7 4 2 -2 8 3 1 -1
result:
ok Correct. (1 test case)
Test #7:
score: 0
Accepted
time: 0ms
memory: 3564kb
input:
10 6 10
output:
Yes 9 1 1 9 9 2 2 8 8 3 3 7 7 4 4 6 6 5 5 5 5 10 6 -4 4 9 7 -3 3 8 8 -2 2 7 9 -1 1
result:
ok Correct. (1 test case)
Test #8:
score: 0
Accepted
time: 0ms
memory: 3560kb
input:
10 8 4
output:
Yes 9 1 1 8 9 10 10 -8 -9 2 2 6 7 9 9 -6 -7 3 8 5 -5 4 7 4 -4 5 6 3 -3 6 5 2 -2 7 3 1 1
result:
ok Correct. (1 test case)
Test #9:
score: 0
Accepted
time: 2ms
memory: 7020kb
input:
999 396 693
output:
Yes 998 1 1 997 998 999 999 -997 -998 2 2 995 996 998 998 -995 -996 3 3 993 994 997 997 -993 -994 4 4 991 992 996 996 -991 -992 5 5 989 990 995 995 -989 -990 6 6 987 988 994 994 -987 -988 7 7 985 986 993 993 -985 -986 8 8 983 984 992 992 -983 -984 9 9 981 982 991 991 -981 -982 10 10 979 980 990 990 ...
result:
ok Correct. (1 test case)
Test #10:
score: 0
Accepted
time: 2ms
memory: 7068kb
input:
999 963 827
output:
Yes 998 1 1 997 998 999 999 -997 -998 2 2 995 996 998 998 -995 -996 3 3 993 994 997 997 -993 -994 4 4 991 992 996 996 -991 -992 5 5 989 990 995 995 -989 -990 6 6 987 988 994 994 -987 -988 7 7 985 986 993 993 -985 -986 8 8 983 984 992 992 -983 -984 9 9 981 982 991 991 -981 -982 10 10 979 980 990 990 ...
result:
ok Correct. (1 test case)
Test #11:
score: 0
Accepted
time: 2ms
memory: 7012kb
input:
999 871 185
output:
Yes 998 1 1 997 998 999 999 -997 -998 2 2 995 996 998 998 -995 -996 3 3 993 994 997 997 -993 -994 4 4 991 992 996 996 -991 -992 5 5 989 990 995 995 -989 -990 6 6 987 988 994 994 -987 -988 7 7 985 986 993 993 -985 -986 8 8 983 984 992 992 -983 -984 9 9 981 982 991 991 -981 -982 10 10 979 980 990 990 ...
result:
ok Correct. (1 test case)
Test #12:
score: 0
Accepted
time: 2ms
memory: 7072kb
input:
999 787 812
output:
Yes 998 1 1 997 998 999 999 -997 -998 2 2 995 996 998 998 -995 -996 3 3 993 994 997 997 -993 -994 4 4 991 992 996 996 -991 -992 5 5 989 990 995 995 -989 -990 6 6 987 988 994 994 -987 -988 7 7 985 986 993 993 -985 -986 8 8 983 984 992 992 -983 -984 9 9 981 982 991 991 -981 -982 10 10 979 980 990 990 ...
result:
ok Correct. (1 test case)
Test #13:
score: 0
Accepted
time: 0ms
memory: 7016kb
input:
999 396 199
output:
Yes 998 1 1 997 998 999 999 -997 -998 2 2 995 996 998 998 -995 -996 3 3 993 994 997 997 -993 -994 4 4 991 992 996 996 -991 -992 5 5 989 990 995 995 -989 -990 6 6 987 988 994 994 -987 -988 7 7 985 986 993 993 -985 -986 8 8 983 984 992 992 -983 -984 9 9 981 982 991 991 -981 -982 10 10 979 980 990 990 ...
result:
ok Correct. (1 test case)
Test #14:
score: 0
Accepted
time: 2ms
memory: 7168kb
input:
999 1 1
output:
Yes 998 999 999 -998 -998 998 998 -997 -997 997 997 -996 -996 996 996 -995 -995 995 995 -994 -994 994 994 -993 -993 993 993 -992 -992 992 992 -991 -991 991 991 -990 -990 990 990 -989 -989 989 989 -988 -988 988 988 -987 -987 987 987 -986 -986 986 986 -985 -985 985 985 -984 -984 984 984 -983 -983 983 ...
result:
ok Correct. (1 test case)
Test #15:
score: 0
Accepted
time: 2ms
memory: 7164kb
input:
999 163 1
output:
Yes 998 999 999 -998 -998 998 998 -997 -997 997 997 -996 -996 996 996 -995 -995 995 995 -994 -994 994 994 -993 -993 993 993 -992 -992 992 992 -991 -991 991 991 -990 -990 990 990 -989 -989 989 989 -988 -988 988 988 -987 -987 987 987 -986 -986 986 986 -985 -985 985 985 -984 -984 984 984 -983 -983 983 ...
result:
ok Correct. (1 test case)
Test #16:
score: 0
Accepted
time: 2ms
memory: 7008kb
input:
999 999 1
output:
Yes 998 1 999 998 -998 2 998 997 -997 3 997 996 -996 4 996 995 -995 5 995 994 -994 6 994 993 -993 7 993 992 -992 8 992 991 -991 9 991 990 -990 10 990 989 -989 11 989 988 -988 12 988 987 -987 13 987 986 -986 14 986 985 -985 15 985 984 -984 16 984 983 -983 17 983 982 -982 18 982 981 -981 19 981 980 -9...
result:
ok Correct. (1 test case)
Test #17:
score: 0
Accepted
time: 2ms
memory: 7040kb
input:
999 1 969
output:
Yes 998 999 1 -998 998 998 2 -997 997 997 3 -996 996 996 4 -995 995 995 5 -994 994 994 6 -993 993 993 7 -992 992 992 8 -991 991 991 9 -990 990 990 10 -989 989 989 11 -988 988 988 12 -987 987 987 13 -986 986 986 14 -985 985 985 15 -984 984 984 16 -983 983 983 17 -982 982 982 18 -981 981 981 19 -980 9...
result:
ok Correct. (1 test case)
Test #18:
score: 0
Accepted
time: 2ms
memory: 7016kb
input:
999 999 780
output:
Yes 998 1 1 998 998 2 2 997 997 3 3 996 996 4 4 995 995 5 5 994 994 6 6 993 993 7 7 992 992 8 8 991 991 9 9 990 990 10 10 989 989 11 11 988 988 12 12 987 987 13 13 986 986 14 14 985 985 15 15 984 984 16 16 983 983 17 17 982 982 18 18 981 981 19 19 980 980 20 20 979 979 21 21 978 978 22 22 977 977 23...
result:
ok Correct. (1 test case)
Test #19:
score: 0
Accepted
time: 0ms
memory: 7020kb
input:
999 1 999
output:
Yes 998 999 1 -998 998 998 2 -997 997 997 3 -996 996 996 4 -995 995 995 5 -994 994 994 6 -993 993 993 7 -992 992 992 8 -991 991 991 9 -990 990 990 10 -989 989 989 11 -988 988 988 12 -987 987 987 13 -986 986 986 14 -985 985 985 15 -984 984 984 16 -983 983 983 17 -982 982 982 18 -981 981 981 19 -980 9...
result:
ok Correct. (1 test case)
Test #20:
score: 0
Accepted
time: 2ms
memory: 7168kb
input:
999 686 999
output:
Yes 998 1 1 998 998 2 2 997 997 3 3 996 996 4 4 995 995 5 5 994 994 6 6 993 993 7 7 992 992 8 8 991 991 9 9 990 990 10 10 989 989 11 11 988 988 12 12 987 987 13 13 986 986 14 14 985 985 15 15 984 984 16 16 983 983 17 17 982 982 18 18 981 981 19 19 980 980 20 20 979 979 21 21 978 978 22 22 977 977 23...
result:
ok Correct. (1 test case)
Test #21:
score: 0
Accepted
time: 2ms
memory: 7036kb
input:
999 999 999
output:
Yes 998 1 1 998 998 2 2 997 997 3 3 996 996 4 4 995 995 5 5 994 994 6 6 993 993 7 7 992 992 8 8 991 991 9 9 990 990 10 10 989 989 11 11 988 988 12 12 987 987 13 13 986 986 14 14 985 985 15 15 984 984 16 16 983 983 17 17 982 982 18 18 981 981 19 19 980 980 20 20 979 979 21 21 978 978 22 22 977 977 23...
result:
ok Correct. (1 test case)
Test #22:
score: 0
Accepted
time: 0ms
memory: 7044kb
input:
1000 757 728
output:
Yes 999 1 1 998 999 1000 1000 -998 -999 2 2 996 997 999 999 -996 -997 3 3 994 995 998 998 -994 -995 4 4 992 993 997 997 -992 -993 5 5 990 991 996 996 -990 -991 6 6 988 989 995 995 -988 -989 7 7 986 987 994 994 -986 -987 8 8 984 985 993 993 -984 -985 9 9 982 983 992 992 -982 -983 10 10 980 981 991 99...
result:
ok Correct. (1 test case)
Test #23:
score: 0
Accepted
time: 2ms
memory: 7144kb
input:
1000 132 993
output:
Yes 999 1 1 998 999 1000 1000 -998 -999 2 2 996 997 999 999 -996 -997 3 3 994 995 998 998 -994 -995 4 4 992 993 997 997 -992 -993 5 5 990 991 996 996 -990 -991 6 6 988 989 995 995 -988 -989 7 7 986 987 994 994 -986 -987 993 8 -985 985 992 9 -984 984 991 10 -983 983 990 11 -982 982 989 12 -981 981 98...
result:
ok Correct. (1 test case)
Test #24:
score: 0
Accepted
time: 0ms
memory: 7012kb
input:
1000 703 499
output:
Yes 999 1 1 998 999 1000 1000 -998 -999 2 2 996 997 999 999 -996 -997 3 3 994 995 998 998 -994 -995 4 4 992 993 997 997 -992 -993 5 5 990 991 996 996 -990 -991 6 6 988 989 995 995 -988 -989 7 7 986 987 994 994 -986 -987 8 8 984 985 993 993 -984 -985 9 9 982 983 992 992 -982 -983 10 10 980 981 991 99...
result:
ok Correct. (1 test case)
Test #25:
score: 0
Accepted
time: 2ms
memory: 7008kb
input:
1000 910 298
output:
Yes 999 1 1 998 999 1000 1000 -998 -999 2 2 996 997 999 999 -996 -997 3 3 994 995 998 998 -994 -995 4 4 992 993 997 997 -992 -993 5 5 990 991 996 996 -990 -991 6 6 988 989 995 995 -988 -989 7 7 986 987 994 994 -986 -987 8 8 984 985 993 993 -984 -985 9 9 982 983 992 992 -982 -983 10 10 980 981 991 99...
result:
ok Correct. (1 test case)
Test #26:
score: 0
Accepted
time: 0ms
memory: 7168kb
input:
1000 171 322
output:
Yes 999 1 1 998 999 1000 1000 -998 -999 2 2 996 997 999 999 -996 -997 3 3 994 995 998 998 -994 -995 4 4 992 993 997 997 -992 -993 5 5 990 991 996 996 -990 -991 6 6 988 989 995 995 -988 -989 7 7 986 987 994 994 -986 -987 8 8 984 985 993 993 -984 -985 9 9 982 983 992 992 -982 -983 10 10 980 981 991 99...
result:
ok Correct. (1 test case)
Test #27:
score: 0
Accepted
time: 2ms
memory: 7044kb
input:
1000 1 1
output:
Yes 999 1000 1000 -999 -999 999 999 -998 -998 998 998 -997 -997 997 997 -996 -996 996 996 -995 -995 995 995 -994 -994 994 994 -993 -993 993 993 -992 -992 992 992 -991 -991 991 991 -990 -990 990 990 -989 -989 989 989 -988 -988 988 988 -987 -987 987 987 -986 -986 986 986 -985 -985 985 985 -984 -984 98...
result:
ok Correct. (1 test case)
Test #28:
score: 0
Accepted
time: 0ms
memory: 7168kb
input:
1000 480 1
output:
Yes 999 1000 1000 -999 -999 999 999 -998 -998 998 998 -997 -997 997 997 -996 -996 996 996 -995 -995 995 995 -994 -994 994 994 -993 -993 993 993 -992 -992 992 992 -991 -991 991 991 -990 -990 990 990 -989 -989 989 989 -988 -988 988 988 -987 -987 987 987 -986 -986 986 986 -985 -985 985 985 -984 -984 98...
result:
ok Correct. (1 test case)
Test #29:
score: 0
Accepted
time: 2ms
memory: 7148kb
input:
1000 1000 1
output:
Yes 999 1 1000 999 -999 2 999 998 -998 3 998 997 -997 4 997 996 -996 5 996 995 -995 6 995 994 -994 7 994 993 -993 8 993 992 -992 9 992 991 -991 10 991 990 -990 11 990 989 -989 12 989 988 -988 13 988 987 -987 14 987 986 -986 15 986 985 -985 16 985 984 -984 17 984 983 -983 18 983 982 -982 19 982 981 -...
result:
ok Correct. (1 test case)
Test #30:
score: 0
Accepted
time: 2ms
memory: 7080kb
input:
1000 1 339
output:
Yes 999 1000 1000 -999 -999 999 999 -998 -998 998 998 -997 -997 997 997 -996 -996 996 996 -995 -995 995 995 -994 -994 994 994 -993 -993 993 993 -992 -992 992 992 -991 -991 991 991 -990 -990 990 990 -989 -989 989 989 -988 -988 988 988 -987 -987 987 987 -986 -986 986 986 -985 -985 985 985 -984 -984 98...
result:
ok Correct. (1 test case)
Test #31:
score: 0
Accepted
time: 2ms
memory: 7008kb
input:
1000 1000 161
output:
Yes 999 1 1000 999 -999 2 999 998 -998 3 998 997 -997 4 997 996 -996 5 996 995 -995 6 995 994 -994 7 994 993 -993 8 993 992 -992 9 992 991 -991 10 991 990 -990 11 990 989 -989 12 989 988 -988 13 988 987 -987 14 987 986 -986 15 986 985 -985 16 985 984 -984 17 984 983 -983 18 983 982 -982 19 982 981 -...
result:
ok Correct. (1 test case)
Test #32:
score: 0
Accepted
time: 0ms
memory: 7012kb
input:
1000 1 1000
output:
Yes 999 1000 1 -999 999 999 2 -998 998 998 3 -997 997 997 4 -996 996 996 5 -995 995 995 6 -994 994 994 7 -993 993 993 8 -992 992 992 9 -991 991 991 10 -990 990 990 11 -989 989 989 12 -988 988 988 13 -987 987 987 14 -986 986 986 15 -985 985 985 16 -984 984 984 17 -983 983 983 18 -982 982 982 19 -981 ...
result:
ok Correct. (1 test case)
Test #33:
score: 0
Accepted
time: 0ms
memory: 7148kb
input:
1000 759 1000
output:
Yes 999 1 1 999 999 2 2 998 998 3 3 997 997 4 4 996 996 5 5 995 995 6 6 994 994 7 7 993 993 8 8 992 992 9 9 991 991 10 10 990 990 11 11 989 989 12 12 988 988 13 13 987 987 14 14 986 986 15 15 985 985 16 16 984 984 17 17 983 983 18 18 982 982 19 19 981 981 20 20 980 980 21 21 979 979 22 22 978 978 23...
result:
ok Correct. (1 test case)
Test #34:
score: 0
Accepted
time: 2ms
memory: 7088kb
input:
1000 1000 1000
output:
Yes 999 1 1 999 999 2 2 998 998 3 3 997 997 4 4 996 996 5 5 995 995 6 6 994 994 7 7 993 993 8 8 992 992 9 9 991 991 10 10 990 990 11 11 989 989 12 12 988 988 13 13 987 987 14 14 986 986 15 15 985 985 16 16 984 984 17 17 983 983 18 18 982 982 19 19 981 981 20 20 980 980 21 21 979 979 22 22 978 978 23...
result:
ok Correct. (1 test case)
Test #35:
score: 0
Accepted
time: 0ms
memory: 3564kb
input:
2 1 1
output:
Yes 1 2 2 -1 -1
result:
ok Correct. (1 test case)
Test #36:
score: 0
Accepted
time: 0ms
memory: 3552kb
input:
2 1 2
output:
Yes 1 2 1 -1 1
result:
ok Correct. (1 test case)
Test #37:
score: 0
Accepted
time: 0ms
memory: 3556kb
input:
2 2 1
output:
Yes 1 1 2 1 -1
result:
ok Correct. (1 test case)
Test #38:
score: 0
Accepted
time: 0ms
memory: 3860kb
input:
2 2 2
output:
Yes 1 1 1 1 1
result:
ok Correct. (1 test case)
Test #39:
score: 0
Accepted
time: 2ms
memory: 5828kb
input:
810 114 514
output:
Yes 809 1 1 808 809 810 810 -808 -809 2 2 806 807 809 809 -806 -807 3 3 804 805 808 808 -804 -805 4 4 802 803 807 807 -802 -803 5 5 800 801 806 806 -800 -801 6 6 798 799 805 805 -798 -799 7 7 796 797 804 804 -796 -797 8 8 794 795 803 803 -794 -795 9 9 792 793 802 802 -792 -793 10 10 790 791 801 801 ...
result:
ok Correct. (1 test case)
Test #40:
score: 0
Accepted
time: 2ms
memory: 5676kb
input:
810 514 114
output:
Yes 809 1 1 808 809 810 810 -808 -809 2 2 806 807 809 809 -806 -807 3 3 804 805 808 808 -804 -805 4 4 802 803 807 807 -802 -803 5 5 800 801 806 806 -800 -801 6 6 798 799 805 805 -798 -799 7 7 796 797 804 804 -796 -797 8 8 794 795 803 803 -794 -795 9 9 792 793 802 802 -792 -793 10 10 790 791 801 801 ...
result:
ok Correct. (1 test case)