QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#496864 | #4218. Hidden Graph | haze | WA | 81ms | 5864kb | C++23 | 2.2kb | 2024-07-28 16:37:19 | 2024-07-28 16:37:19 |
Judging History
answer
/*
Author: Haze
2024/7/28
*/
#include <bits/stdc++.h>
#define irep(i, l, r) for(int i = (l); i <= (r); ++ i)
#define drep(i, r, l) for(int i = (r); i >= (l); -- i)
#define IOS ios::sync_with_stdio(false), cin.tie(nullptr);
using namespace std;
typedef long long ll;
inline ll readL() {
ll s = 0;
bool fl = false;
char ch = (char) getchar();
while (!isdigit(ch)) {
if (ch == '-')fl = true;
ch = (char) getchar();
}
while (isdigit(ch)) {
s = s * 10 + (ch ^ 48);
ch = (char) getchar();
}
return fl ? -s : s;
}
inline int read() {
return (int) (readL());
}
const int mod = 1000000000 + 7;
const int itinf = 1000000999;
const ll llinf = 2e18;
const int N = 500099;
int F[N], G[N];
std::mt19937 rng(std::chrono::system_clock::now().time_since_epoch().count());
array<int, 2> query(vector<int>&node){
if(node.size() == 1){
return {-1, -1};
}
cout << "? " << node.size();
for(int x : node){
cout << " " << F[x];
}
cout << endl;
array<int, 2>ar{};
cin >> ar[0] >> ar[1];
if(ar[0] != -1)ar[0] = G[ar[0]], ar[1] = G[ar[1]];
return ar;
}
void solve() {
int n;
cin >> n;
irep(i, 1, n)F[i] = i, G[i] = i;
shuffle(F + 1, F + n + 1, rng);
irep(i, 1, n){
G[F[i]] = i;
}
vector<vector<int>>col = {{1}};
vector<array<int, 2>>edge;
irep(u, 2, n){
int to = -1;
irep(c, 0, col.size() - 1){
auto vec = col[c];
vec.push_back(u);
auto [i, j] = query(vec);
if(i == -1)to = c;
while(i != -1){
edge.push_back({i, j});
vec.erase(find(vec.begin(), vec.end(), i + j - u));
auto T = query(vec);
i = T[0], j = T[1];
}
}
if(to == -1){
col.push_back({u});
}
else col[to].push_back(u);
}
cout << "! " << edge.size() << endl;
for(auto [u, v] : edge){
cout << F[u] << ' ' << F[v] << endl;
}
}
int main() {
// IOS
int T = 1;
while (T--) {
solve();
}
return 0;
}
详细
Test #1:
score: 100
Accepted
time: 1ms
memory: 5632kb
input:
3 1 2 1 3 2 3
output:
? 2 1 2 ? 2 1 3 ? 2 2 3 ! 3 1 2 1 3 2 3
result:
ok correct
Test #2:
score: 0
Accepted
time: 0ms
memory: 5708kb
input:
10 4 10 4 8 -1 -1 4 5 -1 -1 1 4 -1 -1 -1 -1 -1 -1 -1 -1 2 5 1 2 2 6 -1 -1 -1 -1 -1 -1 -1 -1 3 8 3 10 1 3 3 9 -1 -1 3 7 -1 -1 -1 -1
output:
? 2 4 10 ? 2 4 8 ? 2 10 8 ? 2 4 5 ? 3 10 8 5 ? 2 4 1 ? 4 10 8 5 1 ? 2 4 6 ? 5 10 8 5 1 6 ? 2 4 2 ? 6 10 8 5 1 6 2 ? 5 10 8 1 6 2 ? 4 10 8 6 2 ? 3 10 8 2 ? 3 4 2 9 ? 6 10 8 5 1 6 9 ? 3 4 2 3 ? 7 10 8 5 1 6 9 3 ? 6 10 5 1 6 9 3 ? 5 5 1 6 9 3 ? 4 5 6 9 3 ? 3 5 6 3 ? 4 4 2 3 7 ? 3 4 2 7 ? 7 10 8 5 1 6 9...
result:
ok correct
Test #3:
score: 0
Accepted
time: 1ms
memory: 5860kb
input:
5 5 2 3 2 -1 -1 4 2 -1 -1 2 1 5 1 3 1 4 1
output:
? 2 2 5 ? 2 2 3 ? 2 5 3 ? 2 2 4 ? 3 5 3 4 ? 2 2 1 ? 4 5 3 4 1 ? 3 3 4 1 ? 2 4 1 ! 7 5 2 3 2 4 2 2 1 5 1 3 1 4 1
result:
ok correct
Test #4:
score: 0
Accepted
time: 1ms
memory: 3516kb
input:
3 -1 -1 1 3 2 1
output:
? 2 2 3 ? 3 2 3 1 ? 2 2 1 ! 2 1 3 2 1
result:
ok correct
Test #5:
score: 0
Accepted
time: 0ms
memory: 5856kb
input:
6 4 2 3 2 3 4 2 5 4 5 3 5 -1 -1 -1 -1 3 6 -1 -1 1 2 -1 -1 3 1 -1 -1
output:
? 2 2 4 ? 2 2 3 ? 2 4 3 ? 2 2 5 ? 2 4 5 ? 2 3 5 ? 2 2 6 ? 2 4 6 ? 2 3 6 ? 2 5 6 ? 2 2 1 ? 2 4 1 ? 2 3 1 ? 3 5 6 1 ! 9 4 2 3 2 3 4 2 5 4 5 3 5 3 6 1 2 3 1
result:
ok correct
Test #6:
score: 0
Accepted
time: 0ms
memory: 5736kb
input:
27 -1 -1 -1 -1 21 17 -1 -1 -1 -1 -1 -1 14 19 -1 -1 21 19 -1 -1 14 8 -1 -1 21 8 22 8 -1 -1 -1 -1 22 11 -1 -1 19 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 7 22 -1 -1 -1 -1 27 11 -1 -1 21 27 22 27 19 27 -1 -1 9 20 -1 -1 22 20 -1 -1 -1 -1 -1 -1 -1 -1 21 2 -1 -1 2 19 -1 -1 2 27 -1 -1 17 25 -1 -1 21 25 22 25 -1 -1...
output:
? 2 14 9 ? 3 14 9 17 ? 4 14 9 17 21 ? 3 14 9 21 ? 4 14 9 17 22 ? 2 21 22 ? 4 14 9 17 19 ? 3 9 17 19 ? 3 21 22 19 ? 2 22 19 ? 4 14 9 17 8 ? 3 9 17 8 ? 3 21 22 8 ? 2 22 8 ? 2 19 8 ? 4 14 9 17 11 ? 3 21 22 11 ? 2 21 11 ? 3 19 8 11 ? 2 8 11 ? 5 14 9 17 11 15 ? 3 21 22 15 ? 3 19 8 15 ? 5 14 9 17 11 7 ? 3...
result:
ok correct
Test #7:
score: 0
Accepted
time: 3ms
memory: 5656kb
input:
47 -1 -1 33 32 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 27 40 -1 -1 -1 -1 29 32 -1 -1 -1 -1 -1 -1 27 26 -1 -1 -1 -1 -1 -1 26 24 31 24 -1 -1 -1 -1 26 47 -1 -1 46 3 -1 -1 40 3 26 3 12 3 -1 -1 46 6 -1 -1 6 32 40 6 -1 -1 -1 -1 27 36 -1 -1 40 36 31 36 -1 -1 6 36 -1 -1 19 29 27 19 19 33 -1 -1 19 26 -1 -1 -1 -1...
output:
? 2 33 46 ? 3 33 46 32 ? 2 46 32 ? 3 33 46 31 ? 2 32 31 ? 3 33 46 40 ? 3 32 31 40 ? 3 33 46 27 ? 4 32 31 40 27 ? 3 32 31 27 ? 4 33 46 27 29 ? 4 32 31 40 29 ? 3 31 40 29 ? 5 33 46 27 29 12 ? 4 32 31 40 12 ? 5 33 46 27 29 26 ? 4 33 46 29 26 ? 5 32 31 40 12 26 ? 5 33 46 27 29 24 ? 6 32 31 40 12 26 24 ?...
result:
ok correct
Test #8:
score: 0
Accepted
time: 3ms
memory: 5716kb
input:
38 2 17 -1 -1 -1 -1 23 17 1 23 -1 -1 -1 -1 2 34 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 31 17 31 1 -1 -1 31 33 -1 -1 -1 -1 -1 -1 19 23 -1 -1 31 19 -1 -1 -1 -1 -1 -1 31 18 -1 -1 1 5 -1 -1 18 5 -1 -1 31 5 -1 -1 -1 -1 28 33 28 18 28 23 -1 -1 -1 -1 -1 -1 -1 -1 33 6 6 23 -1 -1 31 6 -1 -1 16 17 -1...
output:
? 2 17 2 ? 2 17 1 ? 2 2 1 ? 2 17 23 ? 3 2 1 23 ? 2 2 23 ? 2 17 34 ? 3 2 1 34 ? 2 1 34 ? 2 23 34 ? 2 17 15 ? 3 2 1 15 ? 3 23 34 15 ? 2 17 33 ? 3 2 1 33 ? 4 23 34 15 33 ? 2 17 31 ? 3 2 1 31 ? 2 2 31 ? 5 23 34 15 33 31 ? 4 23 34 15 31 ? 2 17 19 ? 3 2 1 19 ? 5 23 34 15 33 19 ? 4 34 15 33 19 ? 2 31 19 ? ...
result:
ok correct
Test #9:
score: 0
Accepted
time: 1ms
memory: 5864kb
input:
25 -1 -1 -1 -1 -1 -1 2 8 8 21 -1 -1 -1 -1 -1 -1 2 9 -1 -1 9 8 -1 -1 2 22 22 21 -1 -1 14 22 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 14 3 -1 -1 22 3 -1 -1 -1 -1 -1 -1 24 15 -1 -1 16 3 16 21 -1 -1 16 8 16 14 -1 -1 16 9 -1 -1 5 21 5 2 -1 -1 5 14 5 8 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 20 3 -1 -1 -1 -1...
output:
? 2 21 2 ? 3 21 2 19 ? 4 21 2 19 17 ? 5 21 2 19 17 8 ? 4 21 19 17 8 ? 3 19 17 8 ? 5 21 2 19 17 14 ? 2 8 14 ? 5 21 2 19 17 9 ? 4 21 19 17 9 ? 3 8 14 9 ? 2 14 9 ? 5 21 2 19 17 22 ? 4 21 19 17 22 ? 3 19 17 22 ? 3 8 14 22 ? 2 8 22 ? 2 9 22 ? 5 21 2 19 17 15 ? 3 8 14 15 ? 3 9 22 15 ? 5 21 2 19 17 3 ? 3 8...
result:
ok correct
Test #10:
score: 0
Accepted
time: 1ms
memory: 3824kb
input:
6 -1 -1 -1 -1 5 6 -1 -1 -1 -1 2 5 2 3 -1 -1 -1 -1
output:
? 2 4 1 ? 3 4 1 6 ? 4 4 1 6 5 ? 3 4 1 5 ? 4 4 1 6 2 ? 2 5 2 ? 5 4 1 6 2 3 ? 4 4 1 6 3 ? 2 5 3 ! 3 5 6 2 5 2 3
result:
ok correct
Test #11:
score: 0
Accepted
time: 1ms
memory: 5652kb
input:
3 3 1 2 1 2 3
output:
? 2 1 3 ? 2 1 2 ? 2 3 2 ! 3 3 1 2 1 2 3
result:
ok correct
Test #12:
score: 0
Accepted
time: 1ms
memory: 5696kb
input:
3 -1 -1 2 1 3 1
output:
? 2 2 3 ? 3 2 3 1 ? 2 3 1 ! 2 2 1 3 1
result:
ok correct
Test #13:
score: 0
Accepted
time: 0ms
memory: 5568kb
input:
5 5 1 3 1 -1 -1 -1 -1 -1 -1 2 1 2 5 2 3 -1 -1
output:
? 2 1 5 ? 2 1 3 ? 2 5 3 ? 2 1 4 ? 3 5 3 4 ? 2 1 2 ? 4 5 3 4 2 ? 3 3 4 2 ? 2 4 2 ! 5 5 1 3 1 2 1 2 5 2 3
result:
ok correct
Test #14:
score: 0
Accepted
time: 1ms
memory: 5696kb
input:
3 2 1 -1 -1 -1 -1
output:
? 2 2 1 ? 2 2 3 ? 2 1 3 ! 1 2 1
result:
ok correct
Test #15:
score: 0
Accepted
time: 0ms
memory: 5864kb
input:
5 -1 -1 4 3 -1 -1 -1 -1 -1 -1 3 5 -1 -1 2 5 -1 -1
output:
? 2 1 3 ? 3 1 3 4 ? 2 1 4 ? 3 1 3 2 ? 2 4 2 ? 3 1 3 5 ? 2 1 5 ? 3 4 2 5 ? 2 4 5 ! 3 4 3 3 5 2 5
result:
ok correct
Test #16:
score: 0
Accepted
time: 1ms
memory: 5656kb
input:
93 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 62 92 -1 -1 14 50 62 14 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 62 38 -1 -1 -1 -1 -1 -1 78 38 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 7 71 -1 -1 -1 -1 -1 -1 30 61 -1 -1 62 2 -1 -1 2 42 2 71 2 61 -1 -1 -1 -1 71 86 37 86 -1 -1 -1 -1 44 67 5 44 62 44 -1 -1 -1 ...
output:
? 2 7 5 ? 3 7 5 26 ? 4 7 5 26 67 ? 5 7 5 26 67 50 ? 6 7 5 26 67 50 62 ? 7 7 5 26 67 50 62 92 ? 6 7 5 26 67 50 92 ? 7 7 5 26 67 50 62 14 ? 6 7 5 26 67 62 14 ? 5 7 5 26 67 14 ? 2 92 14 ? 7 7 5 26 67 50 62 16 ? 3 92 14 16 ? 7 7 5 26 67 50 62 91 ? 4 92 14 16 91 ? 7 7 5 26 67 50 62 37 ? 5 92 14 16 91 37 ...
result:
ok correct
Test #17:
score: 0
Accepted
time: 5ms
memory: 5668kb
input:
111 -1 -1 83 84 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 83 77 -1 -1 -1 -1 -1 -1 24 39 -1 -1 69 34 -1 -1 -1 -1 24 74 -1 -1 69 74 -1 -1 83 108 -1 -1 84 108 108 69 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 106 55 -1 -1 83 44 -1 -1 -1 -1 44 8 44 74 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1...
output:
? 2 34 83 ? 3 34 83 84 ? 2 34 84 ? 3 34 83 23 ? 2 84 23 ? 3 34 83 39 ? 3 84 23 39 ? 3 34 83 77 ? 2 34 77 ? 4 84 23 39 77 ? 3 34 83 24 ? 5 84 23 39 77 24 ? 4 84 23 77 24 ? 4 34 83 24 69 ? 3 83 24 69 ? 5 84 23 39 77 69 ? 4 34 83 24 74 ? 3 34 83 74 ? 6 84 23 39 77 69 74 ? 5 84 23 39 77 74 ? 4 34 83 24 ...
result:
ok correct
Test #18:
score: 0
Accepted
time: 2ms
memory: 5836kb
input:
132 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 22 8 -1 -1 47 65 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 55 57 -1 -1 79 30 -1 -1 -1 -1 -1 -1 30 23 -1 -1 55 101 101 18 101 24 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 101 75 -1 -1 67 24 67 70 55 67 -1 -1 67 101 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -...
output:
? 2 79 1 ? 3 79 1 91 ? 4 79 1 91 24 ? 5 79 1 91 24 18 ? 6 79 1 91 24 18 70 ? 7 79 1 91 24 18 70 8 ? 8 79 1 91 24 18 70 8 65 ? 9 79 1 91 24 18 70 8 65 85 ? 10 79 1 91 24 18 70 8 65 85 22 ? 9 79 1 91 24 18 70 65 85 22 ? 10 79 1 91 24 18 70 8 65 85 47 ? 9 79 1 91 24 18 70 8 85 47 ? 2 22 47 ? 10 79 1 91...
result:
ok correct
Test #19:
score: 0
Accepted
time: 0ms
memory: 5576kb
input:
94 -1 -1 -1 -1 42 94 -1 -1 34 45 -1 -1 -1 -1 -1 -1 -1 -1 47 88 -1 -1 42 88 -1 -1 6 45 -1 -1 -1 -1 -1 -1 47 93 -1 -1 93 82 -1 -1 -1 -1 47 13 -1 -1 -1 -1 6 13 -1 -1 -1 -1 42 90 90 82 90 13 90 34 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 42 35 -1 -1 -1 -1 47 41 41 94 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1...
output:
? 2 47 94 ? 3 47 94 45 ? 4 47 94 45 42 ? 3 47 45 42 ? 4 47 94 45 34 ? 3 47 94 34 ? 2 42 34 ? 4 47 94 45 82 ? 3 42 34 82 ? 4 47 94 45 88 ? 3 94 45 88 ? 4 42 34 82 88 ? 3 34 82 88 ? 4 47 94 45 6 ? 3 47 94 6 ? 4 42 34 82 6 ? 2 88 6 ? 4 47 94 45 93 ? 3 94 45 93 ? 4 42 34 82 93 ? 3 42 34 93 ? 3 88 6 93 ?...
result:
ok correct
Test #20:
score: 0
Accepted
time: 5ms
memory: 5660kb
input:
73 -1 -1 -1 -1 -1 -1 -1 -1 35 32 9 35 -1 -1 62 11 11 32 -1 -1 -1 -1 25 6 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 58 35 58 11 -1 -1 -1 -1 -1 -1 42 32 -1 -1 42 25 -1 -1 -1 -1 -1 -1 -1 -1 33 32 -1 -1 -1 -1 -1 -1 72 6 72 9 -1 -1 -1 -1 72 42 -1 -1 46 9 -1 -1 -1 -1 -1 -1 -1 -1 72 44 44 35 -1 -1 -1 -1 -1 -1 50 18 25...
output:
? 2 9 32 ? 3 9 32 6 ? 4 9 32 6 62 ? 5 9 32 6 62 69 ? 6 9 32 6 62 69 35 ? 5 9 6 62 69 35 ? 4 6 62 69 35 ? 6 9 32 6 62 69 11 ? 5 9 32 6 69 11 ? 4 9 6 69 11 ? 2 35 11 ? 6 9 32 6 62 69 25 ? 5 9 32 62 69 25 ? 3 35 11 25 ? 6 9 32 6 62 69 2 ? 4 35 11 25 2 ? 6 9 32 6 62 69 58 ? 5 35 11 25 2 58 ? 4 11 25 2 5...
result:
ok correct
Test #21:
score: 0
Accepted
time: 7ms
memory: 5652kb
input:
77 -1 -1 32 11 -1 -1 -1 -1 -1 -1 33 32 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 73 32 -1 -1 22 73 73 11 63 73 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 32 6 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 56 55 -1 -1 63 56 -1 -1 73 56 -1 -1 -1 -1 74 22 -1 -1 -1 -1 -1 -1 23 32 -1 -1 23 11 63 23 -1 -1 73 23 -1 -1 56 2...
output:
? 2 32 55 ? 3 32 55 11 ? 2 55 11 ? 3 32 55 22 ? 2 11 22 ? 3 32 55 33 ? 2 55 33 ? 3 11 22 33 ? 3 32 55 10 ? 4 11 22 33 10 ? 3 32 55 63 ? 5 11 22 33 10 63 ? 3 32 55 73 ? 2 55 73 ? 6 11 22 33 10 63 73 ? 5 11 33 10 63 73 ? 4 33 10 63 73 ? 3 33 10 73 ? 3 32 55 71 ? 6 11 22 33 10 63 71 ? 2 73 71 ? 3 32 55...
result:
ok correct
Test #22:
score: 0
Accepted
time: 9ms
memory: 5804kb
input:
81 -1 -1 -1 -1 8 12 -1 -1 36 76 -1 -1 36 12 -1 -1 75 12 36 75 69 75 -1 -1 -1 -1 -1 -1 75 21 8 21 -1 -1 -1 -1 -1 -1 35 13 -1 -1 -1 -1 35 21 -1 -1 10 13 -1 -1 10 35 -1 -1 -1 -1 1 76 1 8 -1 -1 -1 -1 69 1 -1 -1 62 8 -1 -1 -1 -1 10 62 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 38 21 -1 -1 64 8 -1 -1 64 1 64 35 ...
output:
? 2 13 8 ? 3 13 8 76 ? 4 13 8 76 12 ? 3 13 76 12 ? 4 13 8 76 36 ? 3 13 8 36 ? 2 12 36 ? 4 13 8 76 75 ? 2 12 75 ? 2 36 75 ? 5 13 8 76 75 69 ? 4 13 8 76 69 ? 2 12 69 ? 2 36 69 ? 5 13 8 76 75 21 ? 4 13 8 76 21 ? 3 13 76 21 ? 2 12 21 ? 3 36 69 21 ? 5 13 8 76 75 35 ? 4 8 76 75 35 ? 2 12 35 ? 4 36 69 21 3...
result:
ok correct
Test #23:
score: 0
Accepted
time: 0ms
memory: 5864kb
input:
93 -1 -1 -1 -1 -1 -1 -1 -1 38 37 60 38 -1 -1 -1 -1 38 3 -1 -1 -1 -1 14 37 -1 -1 14 31 -1 -1 -1 -1 -1 -1 14 30 60 26 26 32 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 26 66 -1 -1 36 64 36 32 -1 -1 -1 -1 -1 -1 37 18 -1 -1 66 18 -1 -1 -1 -1 -1 -1 53 38 -1 -1 53 18 53 26 -1 -1 -1 -1 24 66 -1 -1 24 1...
output:
? 2 64 32 ? 3 64 32 60 ? 4 64 32 60 72 ? 5 64 32 60 72 37 ? 6 64 32 60 72 37 38 ? 5 64 32 60 72 38 ? 4 64 32 72 38 ? 6 64 32 60 72 37 3 ? 2 38 3 ? 7 64 32 60 72 37 3 31 ? 2 38 31 ? 7 64 32 60 72 37 3 14 ? 6 64 32 60 72 3 14 ? 3 38 31 14 ? 2 38 14 ? 7 64 32 60 72 37 3 30 ? 3 38 31 30 ? 2 14 30 ? 7 64...
result:
ok correct
Test #24:
score: 0
Accepted
time: 2ms
memory: 5704kb
input:
37 23 34 18 34 23 18 26 34 -1 -1 18 26 33 34 33 26 -1 -1 33 18 -1 -1 37 26 23 37 37 18 33 37 9 34 9 37 9 23 9 26 9 18 -1 -1 3 37 -1 -1 3 26 3 23 3 18 -1 -1 19 34 19 37 19 23 19 26 19 18 3 19 -1 -1 30 37 -1 -1 30 26 30 23 30 18 33 30 -1 -1 -1 -1 29 34 29 37 -1 -1 29 18 3 29 9 29 33 29 29 19 30 29 7 3...
output:
? 2 34 23 ? 2 34 18 ? 2 23 18 ? 2 34 26 ? 2 23 26 ? 2 18 26 ? 2 34 33 ? 3 23 26 33 ? 2 23 33 ? 2 18 33 ? 2 34 37 ? 3 23 26 37 ? 2 23 37 ? 2 18 37 ? 2 33 37 ? 3 34 37 9 ? 2 37 9 ? 3 23 26 9 ? 2 26 9 ? 2 18 9 ? 2 33 9 ? 3 34 37 3 ? 2 34 3 ? 3 23 26 3 ? 2 23 3 ? 2 18 3 ? 3 33 9 3 ? 3 34 37 19 ? 2 37 19...
result:
ok correct
Test #25:
score: 0
Accepted
time: 0ms
memory: 5712kb
input:
144 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 127 96 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 81 122 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 ...
output:
? 2 72 49 ? 3 72 49 110 ? 4 72 49 110 48 ? 5 72 49 110 48 1 ? 6 72 49 110 48 1 120 ? 7 72 49 110 48 1 120 141 ? 8 72 49 110 48 1 120 141 76 ? 9 72 49 110 48 1 120 141 76 44 ? 10 72 49 110 48 1 120 141 76 44 90 ? 11 72 49 110 48 1 120 141 76 44 90 96 ? 12 72 49 110 48 1 120 141 76 44 90 96 127 ? 11 7...
result:
ok correct
Test #26:
score: 0
Accepted
time: 27ms
memory: 5744kb
input:
561 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 188 297 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 ...
output:
? 2 438 275 ? 3 438 275 467 ? 4 438 275 467 188 ? 5 438 275 467 188 20 ? 6 438 275 467 188 20 160 ? 7 438 275 467 188 20 160 191 ? 8 438 275 467 188 20 160 191 58 ? 9 438 275 467 188 20 160 191 58 66 ? 10 438 275 467 188 20 160 191 58 66 397 ? 11 438 275 467 188 20 160 191 58 66 397 112 ? 12 438 275...
result:
ok correct
Test #27:
score: 0
Accepted
time: 21ms
memory: 5692kb
input:
679 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 589 626 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 235 620 -1 -1 -1 -1 -1 -1 -1 -1 209 248 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1...
output:
? 2 525 447 ? 3 525 447 270 ? 4 525 447 270 398 ? 5 525 447 270 398 78 ? 6 525 447 270 398 78 233 ? 7 525 447 270 398 78 233 134 ? 8 525 447 270 398 78 233 134 629 ? 9 525 447 270 398 78 233 134 629 554 ? 10 525 447 270 398 78 233 134 629 554 593 ? 11 525 447 270 398 78 233 134 629 554 593 209 ? 12 ...
result:
ok correct
Test #28:
score: -100
Wrong Answer
time: 81ms
memory: 3988kb
input:
1000 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 574 335 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1...
output:
? 2 574 60 ? 3 574 60 914 ? 4 574 60 914 427 ? 5 574 60 914 427 278 ? 6 574 60 914 427 278 775 ? 7 574 60 914 427 278 775 471 ? 8 574 60 914 427 278 775 471 673 ? 9 574 60 914 427 278 775 471 673 485 ? 10 574 60 914 427 278 775 471 673 485 903 ? 11 574 60 914 427 278 775 471 673 485 903 31 ? 12 574 ...
result:
wrong answer Query Limit Exceeded (lim = 5000)