답안 #837266

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
837266 2023-08-25T08:53:45 Z Trumling Vision Program (IOI19_vision) C++14
0 / 100
1000 ms 976 KB
#include "vision.h"
#include <bits/stdc++.h>
using namespace std; 

typedef long long ll;
#define pb push_back
#define F first
#define S second
#define enter cout<<'\n';
#define INF 99999999999999999
#define MOD 1000000007
#define all(x) x.begin(),x.end()

void construct_network(int H, int W, int K) 
{
	vector<int>Ns;
	ll idx=0;
	for(int i=0;i<H;i++)
		for(int j=0;j<W;j++)
			{
				int curr=K;
				while(curr>=0)
				{
					if(j+curr>=W || i+(K-curr)>=H)
					{
						curr--;
						continue;
					}
	
					add_and({W*i+j,W*(i+K-curr)+j+curr});
					idx++;
					curr--;
				}
				 curr=1;
				while(curr<K)
				{
					if(j-curr<0 || i+(K-curr)>=H)
					{
						curr--;
						continue;
					}

					add_and({W*i+j,W*(i+K-curr)+j-curr});
					idx++;
					curr++;
				}
			}
	vector<int>ans;
	for(int i=W*H;i<W*H+idx;i++)
	ans.pb(i);

	add_or(ans);
		
		
		
		
}
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 212 KB Output is correct
2 Execution timed out 1070 ms 212 KB Time limit exceeded
3 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 212 KB Output is correct
2 Execution timed out 1070 ms 212 KB Time limit exceeded
3 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 212 KB Output is correct
2 Execution timed out 1070 ms 212 KB Time limit exceeded
3 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 212 KB Output is correct
2 Execution timed out 1070 ms 212 KB Time limit exceeded
3 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 212 KB Output is correct
2 Execution timed out 1048 ms 212 KB Time limit exceeded
3 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 212 KB Output is correct
2 Execution timed out 1075 ms 212 KB Time limit exceeded
3 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Incorrect 1 ms 976 KB WA in grader: Too many instructions
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 212 KB Output is correct
2 Execution timed out 1070 ms 212 KB Time limit exceeded
3 Halted 0 ms 0 KB -