Problem | descsort |
---|---|
User | hackerman123 |
Submission Time | 2023-02-05 23:20:23 |
Score | 0 |
Max Time | N/A |
Max Memory | N/A |
Owl Get a Life
descsort.cpp:8:2: error: expected ‘;’ after struct definition
8 | }
| ^
| ;
descsort.cpp: In member function ‘bool cmp::operator()(int, int)’:
descsort.cpp:6:15: error: expected ‘;’ before ‘}’ token
6 | return a > b
| ^
| ;
7 | }
| ~
descsort.cpp: In function ‘int main()’:
descsort.cpp:18:26: error: no matching function for call to ‘sort(<unresolved overloaded function type>, <unresolved overloaded function type>, cmp)’
18 | sort(v.begin,v.end,cmp());
| ^
In file included from /usr/include/c++/9/algorithm:62,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:65,
from descsort.cpp:1:
/usr/include/c++/9/bits/stl_algo.h:4863:5: note: candidate: ‘template<class _RAIter> void std::sort(_RAIter, _RAIter)’
4863 | sort(_RandomAccessIterator __first, _R