Problem firelord
User aidanvoidout
Submission Time 2025-01-28 21:40:07
Score 0
Max Time N/A
Max Memory N/A

Compile Error

firelord.cpp: In function ‘int main()’:
firelord.cpp:30:74: error: no matching function for call to ‘min(__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type, double)’
30 | (i > 2 ? dp_prev[1] + A[i - 1] + A[i - 2] : 1e9));
| ^
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 firelord.cpp:1:
/usr/include/c++/9/bits/stl_algobase.h:198:5: note: candidate: ‘template<class _Tp> constexpr const _Tp& std::min(const _Tp&, const _Tp&)’
198 | min(const _Tp& __a, const _Tp& __b)
| ^~~
/usr/include/c++/9/bits/stl_algobase.h:198:5: note: template argument deduction/substitution failed:
firelord.cpp:30:74: note: de