Submission #644934

#TimeUsernameProblemLanguageResultExecution timeMemory
644934a_aguiloVision Program (IOI19_vision)C++14
Compilation error
0 ms0 KiB
#include "vision.h" #include<bits/stdc++.h> using namespace std; void construct_network(int H, int W, int K) { int possibilities[K+1]; memset(possibilities, 0, sizeof(possibilities)); for(int w = 0; w <= min(K, W-1); ++w){ int h = K - w; if(h >= H) continue; int act[2]; act[0] = 0; act[1] = h*W + w; possibilities[w] = add_and(act); } add_or(possibilities); }

Compilation message (stderr)

vision.cpp: In function 'void construct_network(int, int, int)':
vision.cpp:15:36: error: could not convert '(int*)(& act)' from 'int*' to 'std::vector<int>'
   15 |         possibilities[w] = add_and(act);
      |                                    ^~~
      |                                    |
      |                                    int*
vision.cpp:17:9: error: could not convert '(int*)(& possibilities)' from 'int*' to 'std::vector<int>'
   17 |  add_or(possibilities);
      |         ^~~~~~~~~~~~~
      |         |
      |         int*