Submission #834388

#TimeUsernameProblemLanguageResultExecution timeMemory
834388Marco_EscandonVision Program (IOI19_vision)C++17
Compilation error
0 ms0 KiB
#include<bits/stdc++.h> using namespace std; typedef int ll; void construct_network(int H, int W, int K) { vector<int> inst; for(int i=0; i<H; i++) { for(int j=0; j<W; j++) { vector<ll> query; for(int l=-K-1; l<=K; l++) { if(i+l<H&& i+l>=0 && j+K-abs(l)<W) { query.push_back((i+l)*W+ j+K-abs(l)); //cout<<(i+l)*W+ j+K-abs(l)<<" "; } } if(query.size()!=0) { ll a= query[0]; if(query.size()!=1) a=add_or(query); inst.push_back(add_and({(i*W+j),a})); } //cout<<"\n"; } } ll a=add_or(inst); }

Compilation message (stderr)

vision.cpp: In function 'void construct_network(int, int, int)':
vision.cpp:23:23: error: 'add_or' was not declared in this scope
   23 |                     a=add_or(query);
      |                       ^~~~~~
vision.cpp:24:32: error: 'add_and' was not declared in this scope
   24 |                 inst.push_back(add_and({(i*W+j),a}));
      |                                ^~~~~~~
vision.cpp:29:7: error: 'add_or' was not declared in this scope
   29 |  ll a=add_or(inst);
      |       ^~~~~~
vision.cpp:29:5: warning: unused variable 'a' [-Wunused-variable]
   29 |  ll a=add_or(inst);
      |     ^