vision.cpp: In function 'void construct_network(int, int, int)':
vision.cpp:17:18: error: 'position' was not declared in this scope
positions.erase(position.begin(), positions.end());
^~~~~~~~
vision.cpp:17:18: note: suggested alternative: 'positions'
positions.erase(position.begin(), positions.end());
^~~~~~~~
positions
vision.cpp:43:12: error: could not convert '& positions.std::vector<int>::operator[](0)' from '__gnu_cxx::__alloc_traits<std::allocator<int> >::value_type* {aka int*}' to 'std::vector<int>'
add_and(&positions[0]);
vision.cpp:53:12: error: could not convert '& positions.std::vector<int>::operator[](0)' from '__gnu_cxx::__alloc_traits<std::allocator<int> >::value_type* {aka int*}' to 'std::vector<int>'
add_and(&positions[0]);
vision.cpp:70:10: error: could not convert '& positions.std::vector<int>::operator[](0)' from '__gnu_cxx::__alloc_traits<std::allocator<int> >::value_type* {aka int*}' to 'std::vector<int>'
add_or(&positions[0]);
vision.cpp:76:10: error: could not convert '& positions.std::vector<int>::operator[](0)' from '__gnu_cxx::__alloc_traits<std::allocator<int> >::value_type* {aka int*}' to 'std::vector<int>'
add_or(&positions[0]);
vision.cpp:80:11: error: could not convert '& positions.std::vector<int>::operator[](0)' from '__gnu_cxx::__alloc_traits<std::allocator<int> >::value_type* {aka int*}' to 'std::vector<int>'
add_and(&positions[0]);
vision.cpp:72:7: warning: unused variable 'options_x' [-Wunused-variable]
int options_x = W - (K - j);
^~~~~~~~~
vision.cpp:88:11: error: could not convert '& positions.std::vector<int>::operator[](0)' from '__gnu_cxx::__alloc_traits<std::allocator<int> >::value_type* {aka int*}' to 'std::vector<int>'
add_and(&positions[0]);
vision.cpp:94:11: error: could not convert '& positions.std::vector<int>::operator[](0)' from '__gnu_cxx::__alloc_traits<std::allocator<int> >::value_type* {aka int*}' to 'std::vector<int>'
add_and(&positions[0]);
vision.cpp:107:9: error: could not convert '& positions.std::vector<int>::operator[](0)' from '__gnu_cxx::__alloc_traits<std::allocator<int> >::value_type* {aka int*}' to 'std::vector<int>'
add_or(&positions[0]);