QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#574966 | #8934. Challenge NPC | hos_lyric | AC ✓ | 14ms | 3968kb | C++14 | 1.6kb | 2024-09-19 09:23:31 | 2024-09-19 09:23:31 |
Judging History
answer
#include <cassert>
#include <cmath>
#include <cstdint>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <algorithm>
#include <bitset>
#include <complex>
#include <deque>
#include <functional>
#include <iostream>
#include <limits>
#include <map>
#include <numeric>
#include <queue>
#include <random>
#include <set>
#include <sstream>
#include <string>
#include <unordered_map>
#include <unordered_set>
#include <utility>
#include <vector>
using namespace std;
using Int = long long;
template <class T1, class T2> ostream &operator<<(ostream &os, const pair<T1, T2> &a) { return os << "(" << a.first << ", " << a.second << ")"; };
template <class T> ostream &operator<<(ostream &os, const vector<T> &as) { const int sz = as.size(); os << "["; for (int i = 0; i < sz; ++i) { if (i >= 256) { os << ", ..."; break; } if (i > 0) { os << ", "; } os << as[i]; } return os << "]"; }
template <class T> void pv(T a, T b) { for (T i = a; i != b; ++i) cerr << *i << " "; cerr << endl; }
template <class T> bool chmin(T &t, const T &f) { if (t > f) { t = f; return true; } return false; }
template <class T> bool chmax(T &t, const T &f) { if (t < f) { t = f; return true; } return false; }
#define COLOR(s) ("\x1b[" s "m")
int main() {
int K;
for (; ~scanf("%d", &K); ) {
K += 2;
printf("%d %d %d\n", K * 2, K * K - K, 2);
for (int u = 0; u < K; ++u) {
if (u) printf(" ");
printf("1 2");
}
puts("");
for (int u = 0; u < K; ++u) for (int v = 0; v < K; ++v) if (u != v) {
printf("%d %d\n", u * 2 + 1, v * 2 + 2);
}
}
return 0;
}
这程序好像有点Bug,我给组数据试试?
详细
Test #1:
score: 100
Accepted
time: 0ms
memory: 3968kb
input:
1
output:
6 6 2 1 2 1 2 1 2 1 4 1 6 3 2 3 6 5 2 5 4
result:
ok ok
Test #2:
score: 0
Accepted
time: 0ms
memory: 3884kb
input:
2
output:
8 12 2 1 2 1 2 1 2 1 2 1 4 1 6 1 8 3 2 3 6 3 8 5 2 5 4 5 8 7 2 7 4 7 6
result:
ok ok
Test #3:
score: 0
Accepted
time: 0ms
memory: 3924kb
input:
3
output:
10 20 2 1 2 1 2 1 2 1 2 1 2 1 4 1 6 1 8 1 10 3 2 3 6 3 8 3 10 5 2 5 4 5 8 5 10 7 2 7 4 7 6 7 10 9 2 9 4 9 6 9 8
result:
ok ok
Test #4:
score: 0
Accepted
time: 0ms
memory: 3848kb
input:
4
output:
12 30 2 1 2 1 2 1 2 1 2 1 2 1 2 1 4 1 6 1 8 1 10 1 12 3 2 3 6 3 8 3 10 3 12 5 2 5 4 5 8 5 10 5 12 7 2 7 4 7 6 7 10 7 12 9 2 9 4 9 6 9 8 9 12 11 2 11 4 11 6 11 8 11 10
result:
ok ok
Test #5:
score: 0
Accepted
time: 0ms
memory: 3932kb
input:
5
output:
14 42 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 4 1 6 1 8 1 10 1 12 1 14 3 2 3 6 3 8 3 10 3 12 3 14 5 2 5 4 5 8 5 10 5 12 5 14 7 2 7 4 7 6 7 10 7 12 7 14 9 2 9 4 9 6 9 8 9 12 9 14 11 2 11 4 11 6 11 8 11 10 11 14 13 2 13 4 13 6 13 8 13 10 13 12
result:
ok ok
Test #6:
score: 0
Accepted
time: 13ms
memory: 3788kb
input:
433
output:
870 188790 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2...
result:
ok ok
Test #7:
score: 0
Accepted
time: 14ms
memory: 3812kb
input:
500
output:
1004 251502 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 ...
result:
ok ok
Test #8:
score: 0
Accepted
time: 14ms
memory: 3924kb
input:
499
output:
1002 250500 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 ...
result:
ok ok
Test #9:
score: 0
Accepted
time: 11ms
memory: 3908kb
input:
457
output:
918 210222 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2...
result:
ok ok
Test #10:
score: 0
Accepted
time: 13ms
memory: 3772kb
input:
497
output:
998 248502 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2...
result:
ok ok
Extra Test:
score: 0
Extra Test Passed