vision.cpp: In function 'void construct_network(int, int, int)':
vision.cpp:3:5: error: 'vector' was not declared in this scope
vector<int> vdiag[H+W-1];
^~~~~~
vision.cpp:3:5: note: suggested alternative:
In file included from /usr/include/c++/7/vector:64:0,
from vision.cpp:1:
/usr/include/c++/7/bits/stl_vector.h:216:11: note: 'std::vector'
class vector : protected _Vector_base<_Tp, _Alloc>
^~~~~~
vision.cpp:3:12: error: expected primary-expression before 'int'
vector<int> vdiag[H+W-1];
^~~
vision.cpp:4:12: error: expected primary-expression before 'int'
vector<int> vdiag2[H+W-1];
^~~
vision.cpp:9:13: error: 'vdiag' was not declared in this scope
vdiag[i+j].push_back(i*W+j);
^~~~~
vision.cpp:10:13: error: 'vdiag2' was not declared in this scope
vdiag2[H-1-i+j].push_back(i*W+j);
^~~~~~
vision.cpp:10:13: note: suggested alternative: 'idx_diag2'
vdiag2[H-1-i+j].push_back(i*W+j);
^~~~~~
idx_diag2
vision.cpp:15:30: error: 'vdiag' was not declared in this scope
idx_diag[i] = add_or(vdiag[i]);
^~~~~
vision.cpp:15:23: error: 'add_or' was not declared in this scope
idx_diag[i] = add_or(vdiag[i]);
^~~~~~
vision.cpp:19:31: error: 'vdiag2' was not declared in this scope
idx_diag2[i] = add_or(vdiag2[i]);
^~~~~~
vision.cpp:19:31: note: suggested alternative: 'idx_diag2'
idx_diag2[i] = add_or(vdiag2[i]);
^~~~~~
idx_diag2
vision.cpp:19:24: error: 'add_or' was not declared in this scope
idx_diag2[i] = add_or(vdiag2[i]);
^~~~~~
vision.cpp:21:12: error: expected primary-expression before 'int'
vector<int> tmp;
^~~
vision.cpp:23:9: error: 'tmp' was not declared in this scope
tmp.push_back(add_and({idx_diag[i], idx_diag[i+K]}));
^~~
vision.cpp:23:23: error: 'add_and' was not declared in this scope
tmp.push_back(add_and({idx_diag[i], idx_diag[i+K]}));
^~~~~~~
vision.cpp:26:12: error: expected primary-expression before 'int'
vector<int> tmp2; // if any fail, we fail
^~~
vision.cpp:27:12: error: expected primary-expression before 'int'
vector<int> vtmp;
^~~
vision.cpp:28:12: error: expected primary-expression before 'int'
vector<int> vtmp2;
^~~
vision.cpp:30:9: error: 'vtmp' was not declared in this scope
vtmp.push_back(idx_diag[i]);
^~~~
vision.cpp:31:9: error: 'vtmp2' was not declared in this scope
vtmp2.push_back(idx_diag2[i]);
^~~~~
vision.cpp:40:9: error: 'tmp2' was not declared in this scope
tmp2.push_back(add_and({idx_diag[i], add_or(vtmp)}));
^~~~
vision.cpp:40:53: error: 'vtmp' was not declared in this scope
tmp2.push_back(add_and({idx_diag[i], add_or(vtmp)}));
^~~~
vision.cpp:40:46: error: 'add_or' was not declared in this scope
tmp2.push_back(add_and({idx_diag[i], add_or(vtmp)}));
^~~~~~
vision.cpp:40:24: error: 'add_and' was not declared in this scope
tmp2.push_back(add_and({idx_diag[i], add_or(vtmp)}));
^~~~~~~
vision.cpp:41:54: error: 'vtmp2' was not declared in this scope
tmp2.push_back(add_and({idx_diag2[i], add_or(vtmp2)}));
^~~~~
vision.cpp:46:21: error: 'tmp' was not declared in this scope
add_and({add_or(tmp), add_not(add_or(tmp2))});
^~~
vision.cpp:46:14: error: 'add_or' was not declared in this scope
add_and({add_or(tmp), add_not(add_or(tmp2))});
^~~~~~
vision.cpp:46:42: error: 'tmp2' was not declared in this scope
add_and({add_or(tmp), add_not(add_or(tmp2))});
^~~~
vision.cpp:46:27: error: 'add_not' was not declared in this scope
add_and({add_or(tmp), add_not(add_or(tmp2))});
^~~~~~~
vision.cpp:46:5: error: 'add_and' was not declared in this scope
add_and({add_or(tmp), add_not(add_or(tmp2))});
^~~~~~~