# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
319454 |
2020-11-05T10:39:45 Z |
shaf_wa_nur |
ICC (CEOI16_icc) |
C++17 |
|
447 ms |
768 KB |
#include <bits/stdc++.h>
#include "icc.h"
using namespace std;
void run(int n) {
int cnt = 0;
while (cnt != n - 1) {
for (int bit = 0; bit < 7; bit++) {
vector<int> A;
vector<int> B;
for (int x = 1; x <= n; x++) {
bool on = (x >> bit) & 1;
(on ? A.push_back(x) : B.push_back(x));
}
if ((int) A.size() > 0 and (int) B.size() > 0) {
int a[(int) A.size()];
for (int i = 0; i < (int) A.size(); i++) {
a[i] = A[i];
}
int b[(int) B.size()];
for (int i = 0; i < (int) B.size(); i++) {
b[i] = B[i];
}
int ret = query((int) A.size(), (int) B.size(), a, b);
if (ret) {
for (int x : A) {
for (int y : B) {
int _a[] = {x};
int _b[] = {y};
ret = query(1, 1, _a, _b);
if (ret) {
cnt += 1;
setRoad(x, y);
}
}
}
}
}
}
}
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
22 ms |
768 KB |
Wrong road! |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
144 ms |
492 KB |
Wrong road! |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
447 ms |
564 KB |
Number of queries more than 4500 out of 2250 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
358 ms |
620 KB |
Number of queries more than 4000 out of 2000 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
319 ms |
576 KB |
Number of queries more than 3550 out of 1775 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
301 ms |
568 KB |
Number of queries more than 3250 out of 1625 |
2 |
Halted |
0 ms |
0 KB |
- |