Submission #1050234

# Submission time Handle Problem Language Result Execution time Memory
1050234 2024-08-09T08:08:17 Z Halit Vision Program (IOI19_vision) C++17
12 / 100
1 ms 604 KB
#include "vision.h"
#include <bits/stdc++.h>

void construct_network(int H, int W, int K) {
  if (H == 1 || W == 1) {
    std::vector<int> idx;
    for (int i = 0;i + K < H*W; ++i) {
      idx.push_back(add_and({i, i+K}));
    }
	  add_or(idx);
    return;
  }
  if (H * W <= 900) {
    std::vector<int> imp;
    for (int i = 0;i < H*W; ++i) {
      std::vector<int> idx;
      for (int j = i+1;j < H*W; ++j) {
        int x1 = i / W;
        int y1 = i % W;
        int x2 = j / W;
        int y2 = j % W;
        if (std::abs(x1 - x2) + std::abs(y1 - y2) == K) {
          idx.push_back(j);
        }
      }
      imp.push_back(add_and(std::vector<int>{i, (add_or(idx))}));
    }
    add_or(imp);
    return;
  }
}
# Verdict Execution time Memory Grader output
1 Correct 0 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 0 ms 348 KB Output is correct
5 Incorrect 0 ms 348 KB WA in grader: Instruction with no inputs
6 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 0 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 0 ms 348 KB Output is correct
5 Incorrect 0 ms 348 KB WA in grader: Instruction with no inputs
6 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 0 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 0 ms 348 KB Output is correct
5 Incorrect 0 ms 348 KB WA in grader: Instruction with no inputs
6 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 0 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 0 ms 348 KB Output is correct
5 Incorrect 0 ms 348 KB WA in grader: Instruction with no inputs
6 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 0 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 0 ms 348 KB Output is correct
5 Correct 0 ms 348 KB Output is correct
6 Correct 0 ms 604 KB Output is correct
7 Correct 0 ms 348 KB Output is correct
8 Correct 0 ms 348 KB Output is correct
9 Correct 0 ms 348 KB Output is correct
10 Correct 0 ms 348 KB Output is correct
11 Correct 1 ms 348 KB Output is correct
12 Correct 0 ms 348 KB Output is correct
13 Correct 0 ms 348 KB Output is correct
14 Correct 0 ms 348 KB Output is correct
15 Correct 0 ms 348 KB Output is correct
16 Correct 0 ms 348 KB Output is correct
17 Correct 0 ms 348 KB Output is correct
18 Correct 0 ms 348 KB Output is correct
19 Correct 1 ms 348 KB Output is correct
20 Correct 0 ms 348 KB Output is correct
21 Correct 0 ms 348 KB Output is correct
22 Correct 0 ms 348 KB Output is correct
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 348 KB WA in grader: Instruction with no inputs
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 348 KB Integer parameter [name=num_gates] equals to 0, violates the range [1, 10000]
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 0 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 0 ms 348 KB Output is correct
5 Incorrect 0 ms 348 KB WA in grader: Instruction with no inputs
6 Halted 0 ms 0 KB -