Submission #617883

#TimeUsernameProblemLanguageResultExecution timeMemory
617883Minindu2006Vision Program (IOI19_vision)C++14
0 / 100
255 ms1020 KiB
#include "vision.h" #include <bits/stdc++.h> using namespace std; int h, w, k; void solve() { vector<int> allops; for (int i = 0; i < h; i++) { for (int j = 0; j < w; j++) { vector<int> kDis; for (int x = 0; x < h; x++) { for (int y = 0; y < w; y++) { if (abs(x - i) + abs(y - i) == k) kDis.push_back(x * w + y); } } allops.push_back(add_and({i * w + j, add_or(kDis)})); } } add_or(allops); } void solve6() { vector<int> kDis; for (int x = 0; x < h; x++) { for (int y = 0; y < w; y++) { if (abs(x - 0) + abs(y - 0) == k) kDis.push_back(x * w + y); } } add_and({0, add_or(kDis)}); } void construct_network(int H, int W, int K) { h = H, w = W, k = K; solve(); }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...