treasure.cpp:17:19: error: ambiguating new declaration of 'std::vector<long long int> encode(std::vector<std::pair<int, int> >)'
17 | vector<long long> encode(vector<pair<int, int>> P) {
| ^~~~~~
In file included from treasure.cpp:1:
treasure.h:4:18: note: old declaration 'std::vector<int> encode(std::vector<std::pair<int, int> >)'
4 | std::vector<int> encode(std::vector<std::pair<int, int>> P);
| ^~~~~~
treasure.cpp: In function 'std::vector<std::pair<int, int> > decode(std::vector<long long int>)':
treasure.cpp:76:32: error: no matching function for call to 'min(<brace-enclosed initializer list>)'
76 | int match = min({count_rem, it->second, z_it->second});
| ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/13/vector:62,
from treasure.h:1:
/usr/include/c++/13/bits/stl_algobase.h:233:5: note: candidate: 'template<class _Tp> constexpr const _Tp& std::min(const _Tp&, const _Tp&)'
233 | min(const _Tp& __a, const _Tp& __b)
| ^~~
/usr/include/c++/13/bits/stl_algobase.h:233:5: note: template argument deduction/substitution failed:
treasure.cpp:76:32: note: candidate expects 2 arguments, 1 provided
76 | int match = min({count_rem, it->second, z_it->second});
| ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/13/bits/stl_algobase.h:281:5: note: candidate: 'template<class _Tp, class _Compare> constexpr const _Tp& std::min(const _Tp&, const _Tp&, _Compare)'
281 | min(const _Tp& __a, const _Tp& __b, _Compare __comp)
| ^~~
/usr/include/c++/13/bits/stl_algobase.h:281:5: note: template argument deduction/substitution failed:
treasure.cpp:76:32: note: candidate expects 3 arguments, 1 provided
76 | int match = min({count_rem, it->second, z_it->second});
| ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~