Problem | 4russians |
---|---|
User | ZivTheONe |
Submission Time | 2024-04-14 17:43:12 |
Score | 0 |
Max Time | N/A |
Max Memory | N/A |
Owl Get a Life
4russians.cpp: In member function ‘ll Solution::helper(ll, ll)’:
4russians.cpp:32:41: error: no matching function for call to ‘max(int, ll)’
32 | DP[ind][K] = max(0, helper(ind + 1, K));
| ^
In file included from /usr/include/c++/9/bits/char_traits.h:39,
from /usr/include/c++/9/ios:40,
from /usr/include/c++/9/ostream:38,
from /usr/include/c++/9/iostream:39,
from 4russians.cpp:1:
/usr/include/c++/9/bits/stl_algobase.h:222:5: note: candidate: ‘template<class _Tp> constexpr const _Tp& std::max(const _Tp&, const _Tp&)’
222 | max(const _Tp& __a, const _Tp& __b)
| ^~~
/usr/include/c++/9/bits/stl_algobase.h:222:5: note: template argument deduction/substitution failed:
4russians.cpp:32:41: note: deduced conflicting types for parameter ‘const _Tp’ (‘int’ and ‘ll’ {aka ‘long long int’})
32 | DP[ind][K] = ma