제출 #585482

#제출 시각아이디문제언어결과실행 시간메모리
585482HanksburgerVision Program (IOI19_vision)C++17
52 / 100
9 ms1232 KiB
#include "vision.h" #include <bits/stdc++.h> using namespace std; void construct_network(int H, int W, int K) { if (H*W<=5000) { vector<int> vec; for (int i=0; i<H; i++) { for (int j=0; j<W; j++) { vector<int> v, w; for (int k=0; k<K; k++) { int x=i+k, y=j+K-k; if (0<=x && x<H && 0<=y && y<W) v.push_back(x*W+y); } for (int k=0; k<K; k++) { int x=i+K-k, y=j-k; if (0<=x && x<H && 0<=y && y<W) v.push_back(x*W+y); } if (v.size()) { w.push_back(i*W+j); w.push_back(add_or(v)); vec.push_back(add_and(w)); } } } add_or(vec); } else { vector<int> v; for (int i=0; i<=K; i++) { int x=i, y=K-i; if (0<=x && x<H && 0<=y && y<W) v.push_back(x*W+y); } add_or(v); } }
#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...