Submission #646783

# Submission time Handle Problem Language Result Execution time Memory
646783 2022-09-30T15:44:36 Z ALI Vision Program (IOI19_vision) C++14
0 / 100
2 ms 1232 KB
#include "vision.h"
#include <bits/stdc++.h>
#define pb push_back
using namespace std;

void construct_network(int H, int W, int K){
    vector<int> query(H*W);
    int counter=H*W;
    for(int i=0;i<H;i++){
        for(int j=0;j<W;j++){
            vector<int> a;
            for(int p=i;p<H&&p<=i+K;p++){
                int p2=K+i-p+j;
                if(p2>=W) continue;
                a.pb(p*W+p2);
            }
            if(a.size()>0){
                add_or(a);
                query[i*W+j]=counter;
                counter++;
            }
            query[i*W+j]=-1;
        }
    }
    vector<int> b;
    for(int i=0;i<H;i++){
        for(int j=0;j<W;j++) if (query[i*W+j]!=-1){
            vector<int> a;
            a.pb(query[i*W+j]);
            a.pb(i*W+j);
            add_and(a);
            b.push_back(counter);
            counter++;
        }
    }
    if(b.size()==0) return;
    add_or(b);
}
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 212 KB on inputs (0, 0), (0, 1), expected 1, but computed 0
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 212 KB on inputs (0, 0), (0, 1), expected 1, but computed 0
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 212 KB on inputs (0, 0), (0, 1), expected 1, but computed 0
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 212 KB on inputs (0, 0), (0, 1), expected 1, but computed 0
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 212 KB on inputs (0, 0), (0, 1), expected 1, but computed 0
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 212 KB on inputs (0, 0), (0, 1), expected 1, but computed 0
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 2 ms 1232 KB WA in grader: Too many instructions
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 212 KB on inputs (0, 0), (0, 1), expected 1, but computed 0
2 Halted 0 ms 0 KB -