답안 #370345

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
370345 2021-02-23T20:31:16 Z MilosMilutinovic Vision Program (IOI19_vision) C++14
0 / 100
1 ms 364 KB
#include <bits/stdc++.h>
#include "vision.h"
using namespace std;
#define pb push_back
int h,w,k;
int Get(int i,int j){return i*h+j;}
void SolveBF(){
	vector<int> ask;
	int cnt=h*w;
	for(int i=0;i<h;i++){
		for(int j=0;j<w;j++){
			for(int x=i;x<h;x++){
				for(int y=j;y<w;y++){
					int dist=x-i+y-j;
					if(dist!=k)continue;
					add_and({Get(i,j),Get(x,y)});
					ask.pb(cnt);
					cnt++;
				}
			}
		}
	}
	add_or(ask);
}
void construct_network(int H,int W,int K){
	h=H,w=W,k=K;
	if(max(H,W)<=30){
		SolveBF();
		return;
	}
}
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 364 KB Output is correct
2 Correct 0 ms 364 KB Output is correct
3 Incorrect 0 ms 364 KB WA in grader: Invalid index
4 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 364 KB Output is correct
2 Correct 0 ms 364 KB Output is correct
3 Incorrect 0 ms 364 KB WA in grader: Invalid index
4 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 364 KB Output is correct
2 Correct 0 ms 364 KB Output is correct
3 Incorrect 0 ms 364 KB WA in grader: Invalid index
4 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 364 KB Output is correct
2 Correct 0 ms 364 KB Output is correct
3 Incorrect 0 ms 364 KB WA in grader: Invalid index
4 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Incorrect 0 ms 364 KB Integer parameter [name=num_gates] equals to 0, violates the range [1, 10000]
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 364 KB Output is correct
2 Correct 1 ms 364 KB Output is correct
3 Incorrect 1 ms 364 KB Integer parameter [name=num_gates] equals to 0, violates the range [1, 10000]
4 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Incorrect 1 ms 364 KB Integer parameter [name=num_gates] equals to 0, violates the range [1, 10000]
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 364 KB Output is correct
2 Correct 0 ms 364 KB Output is correct
3 Incorrect 0 ms 364 KB WA in grader: Invalid index
4 Halted 0 ms 0 KB -