QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#99954 | #5255. Greedy Drawers | cardinal_city# | AC ✓ | 2ms | 3528kb | C++20 | 1.4kb | 2023-04-24 07:43:57 | 2023-04-24 07:44:01 |
Judging History
answer
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
// cin.tie(0)->sync_with_stdio(0);
int n; cin >> n;
int m = n / 8;
int prints1 = 0;
for (int i = 0; i < m; i++) {
int left = 4 * i + 1;
int right = 1000 - 3 * i;
for (int j = 0; j < 3; j++) {
cout << left << " " << right << "\n";
}
cout << left + 1 << " " << right - 1 << "\n";
cout << left + 2 << " " << right - 2 << "\n";
for (int j = 0; j < 3; j++) {
cout << left + 3 << " " << right - 2 << "\n";
}
prints1 += 8;
}
for (int i = 0; i < n % 8; i++) {
cout << 300 + i << " " << 700 + i << "\n";
prints1++;
}
assert(prints1 == n);
cout << "\n";
int prints2 = 0;
for (int i = 0; i < m; i++) {
int left = 4 * i + 1;
int right = 1000 - 3 * i;
for (int j = 0; j < 3; j++) {
cout << left << " " << right << "\n";
}
cout << left + 1 << " " << right << "\n";
cout << left + 2 << " " << right - 1 << "\n";
for (int j = 0; j < 3; j++) {
cout << left + 3 << " " << right - 2 << "\n";
}
prints2 += 8;
}
for (int i = 0; i < n % 8; i++) {
cout << 300 + i << " " << 700 + i << "\n";
prints2++;
}
assert(prints2 == n);
}
詳細信息
Test #1:
score: 100
Accepted
time: 0ms
memory: 3304kb
input:
150
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #2:
score: 0
Accepted
time: 2ms
memory: 3476kb
input:
151
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #3:
score: 0
Accepted
time: 2ms
memory: 3292kb
input:
152
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #4:
score: 0
Accepted
time: 2ms
memory: 3408kb
input:
153
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #5:
score: 0
Accepted
time: 2ms
memory: 3348kb
input:
154
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #6:
score: 0
Accepted
time: 1ms
memory: 3524kb
input:
155
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #7:
score: 0
Accepted
time: 2ms
memory: 3428kb
input:
156
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #8:
score: 0
Accepted
time: 2ms
memory: 3476kb
input:
157
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #9:
score: 0
Accepted
time: 2ms
memory: 3320kb
input:
158
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #10:
score: 0
Accepted
time: 2ms
memory: 3368kb
input:
159
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #11:
score: 0
Accepted
time: 2ms
memory: 3292kb
input:
160
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #12:
score: 0
Accepted
time: 2ms
memory: 3528kb
input:
161
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #13:
score: 0
Accepted
time: 0ms
memory: 3340kb
input:
162
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #14:
score: 0
Accepted
time: 0ms
memory: 3368kb
input:
163
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #15:
score: 0
Accepted
time: 2ms
memory: 3364kb
input:
164
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #16:
score: 0
Accepted
time: 2ms
memory: 3312kb
input:
165
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #17:
score: 0
Accepted
time: 2ms
memory: 3340kb
input:
166
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #18:
score: 0
Accepted
time: 0ms
memory: 3516kb
input:
167
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #19:
score: 0
Accepted
time: 1ms
memory: 3520kb
input:
168
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy
Test #20:
score: 0
Accepted
time: 2ms
memory: 3300kb
input:
250
output:
1 1000 1 1000 1 1000 2 999 3 998 4 998 4 998 4 998 5 997 5 997 5 997 6 996 7 995 8 995 8 995 8 995 9 994 9 994 9 994 10 993 11 992 12 992 12 992 12 992 13 991 13 991 13 991 14 990 15 989 16 989 16 989 16 989 17 988 17 988 17 988 18 987 19 986 20 986 20 986 20 986 21 985 21 985 21 985 22 984 23 983 2...
result:
ok you killed Janko's strategy