#include "vision.h"
#include<bits/stdc++.h>
using namespace std;
#define pb push_back
#define fr first
#define sc second
#define mp make_pair
#define all(x) x.begin(),x.end()
void construct_network(int n, int m, int k) {
// std::vector<int> Ns;
// Ns = {0, 1};
// int a = add_and(Ns);
// Ns = {0, a};
// int b = add_or(Ns);
// Ns = {0, 1, b};
// int c = add_xor(Ns);
// add_not(c);
int last = n*m-1;
for(int i = 0; i < n; i++) {
for(int j = 0; j < m; j++) {
for(int ii = 0; ii < n; ii++) {
for(int jj = 0; jj < m; jj++) {
if(abs(i-ii)+abs(j-jj) == k && i*m+j < ii*m+jj && i == 0 && j == 0) {
last = add_and(vector<int>{i*m+j,ii*m+jj});
}
}
}
}
}
vector<int> vec;
for(int i = n*m; i <= last; i++) vec.pb(i);
add_or(vec);
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
1 ms |
212 KB |
on inputs (0, 1), (0, 2), expected 1, but computed 0 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
1 ms |
212 KB |
on inputs (0, 1), (0, 2), expected 1, but computed 0 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
1 ms |
212 KB |
on inputs (0, 1), (0, 2), expected 1, but computed 0 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
1 ms |
212 KB |
on inputs (0, 1), (0, 2), expected 1, but computed 0 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
0 ms |
212 KB |
on inputs (0, 1), (0, 2), expected 1, but computed 0 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
212 KB |
Output is correct |
2 |
Correct |
0 ms |
212 KB |
Output is correct |
3 |
Correct |
8 ms |
296 KB |
Output is correct |
4 |
Correct |
8 ms |
212 KB |
Output is correct |
5 |
Correct |
8 ms |
212 KB |
Output is correct |
6 |
Correct |
8 ms |
296 KB |
Output is correct |
7 |
Correct |
8 ms |
300 KB |
Output is correct |
8 |
Correct |
25 ms |
280 KB |
Output is correct |
9 |
Correct |
31 ms |
212 KB |
Output is correct |
10 |
Correct |
27 ms |
212 KB |
Output is correct |
11 |
Correct |
25 ms |
212 KB |
Output is correct |
12 |
Correct |
25 ms |
212 KB |
Output is correct |
13 |
Correct |
1 ms |
212 KB |
Output is correct |
14 |
Correct |
1 ms |
212 KB |
Output is correct |
15 |
Correct |
1 ms |
212 KB |
Output is correct |
16 |
Correct |
1 ms |
300 KB |
Output is correct |
17 |
Correct |
1 ms |
304 KB |
Output is correct |
18 |
Correct |
1 ms |
212 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
288 ms |
276 KB |
Output is correct |
21 |
Correct |
317 ms |
292 KB |
Output is correct |
22 |
Correct |
287 ms |
288 KB |
Output is correct |
23 |
Correct |
294 ms |
212 KB |
Output is correct |
24 |
Correct |
275 ms |
276 KB |
Output is correct |
25 |
Correct |
286 ms |
292 KB |
Output is correct |
26 |
Correct |
266 ms |
212 KB |
Output is correct |
27 |
Execution timed out |
1070 ms |
276 KB |
Time limit exceeded |
28 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Execution timed out |
1072 ms |
272 KB |
Time limit exceeded |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
1 ms |
212 KB |
on inputs (0, 1), (0, 2), expected 1, but computed 0 |
2 |
Halted |
0 ms |
0 KB |
- |