Submission #319476

# Submission time Handle Problem Language Result Execution time Memory
319476 2020-11-05T11:00:56 Z shaf_wa_nur ICC (CEOI16_icc) C++17
0 / 100
460 ms 808 KB
#include <bits/stdc++.h>

#ifndef LOCAL
  #include "icc.h"
#endif 

using namespace std;

void setRoad(int a, int b);
int query(int size_a, int size_b, int a[], int b[]);

void run(int n) {
  set<pair<int, int>> st;
  while (true) {
    for (int x = 1; x <= n; x++) {
      for (int y = x + 1; y <= n; y++) {
        int a[1] = {x};
        int b[1] = {y};
        int ret = query(1, 1, a, b);
        if (ret and !st.count({x, y}) and !st.count({y, x})) {
          st.emplace(y, x);
          st.emplace(x, y);
          setRoad(x, y);
        }
      }
    }
  }
}
# Verdict Execution time Memory Grader output
1 Correct 78 ms 492 KB Ok! 1379 queries used.
2 Incorrect 13 ms 492 KB Wrong road!
# Verdict Execution time Memory Grader output
1 Incorrect 258 ms 612 KB Wrong road!
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 460 ms 612 KB Number of queries more than 4500 out of 2250
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 444 ms 808 KB Number of queries more than 4000 out of 2000
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 394 ms 612 KB Number of queries more than 3550 out of 1775
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 357 ms 612 KB Number of queries more than 3250 out of 1625
2 Halted 0 ms 0 KB -