nile.cpp:6:27: error: expected ';' at end of member declaration
6 | struct artifact{int w,a,b,c};
| ^
| ;
nile.cpp: In function 'std::vector<long long int> calculate_costs(std::vector<int>, std::vector<int>, std::vector<int>, std::vector<int>)':
nile.cpp:12:26: error: no matching function for call to 'accumulate(std::vector<int>::iterator, std::vector<int>::iterator)'
12 | return accumulate(b.begin(),b.end())+(n%2?v.back().c:0);
| ~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/13/numeric:62,
from /usr/include/x86_64-linux-gnu/c++/13/bits/stdc++.h:58,
from nile.cpp:1:
/usr/include/c++/13/bits/stl_numeric.h:134:5: note: candidate: 'template<class _InputIterator, class _Tp> constexpr _Tp std::accumulate(_InputIterator, _InputIterator, _Tp)'
134 | accumulate(_InputIterator __first, _InputIterator __last, _Tp __init)
| ^~~~~~~~~~
/usr/include/c++/13/bits/stl_numeric.h:134:5: note: template argument deduction/substitution failed:
nile.cpp:12:26: note: candidate expects 3 arguments, 2 provided
12 | return accumulate(b.begin(),b.end())+(n%2?v.back().c:0);
| ~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
/usr/include/c++/13/bits/stl_numeric.h:161:5: note: candidate: 'template<class _InputIterator, class _Tp, class _BinaryOperation> constexpr _Tp std::accumulate(_InputIterator, _InputIterator, _Tp, _BinaryOperation)'
161 | accumulate(_InputIterator __first, _InputIterator __last, _Tp __init,
| ^~~~~~~~~~
/usr/include/c++/13/bits/stl_numeric.h:161:5: note: template argument deduction/substitution failed:
nile.cpp:12:26: note: candidate expects 4 arguments, 2 provided
12 | return accumulate(b.begin(),b.end())+(n%2?v.back().c:0);
| ~~~~~~~~~~^~~~~~~~~~~~~~~~~~~