Problem potatosalad
User xiaocai918
Submission Time 2026-11-10 11:04:03
Score 0
Max Time N/A
Max Memory N/A

Compile Error

potatosalad.cpp: In function ‘int main()’:
potatosalad.cpp:16:38: error: no matching function for call to ‘reverse<int>()’
16 | sort(M.begin(),M.end(),reverse<int>());
| ^
In file included from /usr/include/c++/9/algorithm:62,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:65,
from potatosalad.cpp:1:
/usr/include/c++/9/bits/stl_algo.h:1186:5: note: candidate: ‘void std::reverse(_BIter, _BIter) [with _BIter = int]’
1186 | reverse(_BidirectionalIterator __first, _BidirectionalIterator __last)
| ^~~~~~~
/usr/include/c++/9/bits/stl_algo.h:1186:5: note: candidate expects 2 arguments, 0 provided
In file included from /usr/include/c++/9/algorithm:71,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:65,
from potatosalad.cpp:1:
/usr/include/c++/9/pstl/glue_algorithm_defs.h:249:1: note: candidate: ‘