cave.cpp: In function 'void exploreCave(int)':
cave.cpp:49:30: error: cannot convert 'std::vector<int>' to 'int*'
49 | int res = tryCombination(comb);
| ^~~~
| |
| std::vector<int>
In file included from cave.cpp:3:
cave.h:8:24: note: initializing argument 1 of 'int tryCombination(int*)'
8 | int tryCombination(int S[]);
| ~~~~^~~
cave.cpp:65:13: error: reference to 'negate' is ambiguous
65 | negate(comb, known);
| ^~~~~~
In file included from /usr/include/c++/13/bits/refwrap.h:39,
from /usr/include/c++/13/vector:68,
from cave.cpp:1:
/usr/include/c++/13/bits/stl_function.h:175:12: note: candidates are: 'template<class _Tp> struct std::negate'
175 | struct negate;
| ^~~~~~
cave.cpp:13:6: note: 'void negate(std::vector<int>&, const std::unordered_set<int>&, int, int)'
13 | void negate(vector<int>& comb, const unordered_set<int>& known, int L, int R) {
| ^~~~~~
cave.cpp:67:34: error: cannot convert 'std::vector<int>' to 'int*'
67 | res = tryCombination(comb);
| ^~~~
| |
| std::vector<int>
cave.h:8:24: note: initializing argument 1 of 'int tryCombination(int*)'
8 | int tryCombination(int S[]);
| ~~~~^~~
cave.cpp:101:12: error: cannot convert 'std::vector<int>' to 'int*'
101 | answer(inter, pos);
| ^~~~~
| |
| std::vector<int>
cave.h:9:17: note: initializing argument 1 of 'void answer(int*, int*)'
9 | void answer(int S[], int D[]);
| ~~~~^~~