Problem sort
User ZachTAD
Submission Time 2024-02-17 15:49:49
Score 0
Max Time N/A
Max Memory N/A

Compile Error

sort.cpp: In function ‘int main()’:
sort.cpp:24:31: error: no matching function for call to ‘sort(std::vector<std::__cxx11::basic_string<char> >::iterator, std::vector<std::__cxx11::basic_string<char> >::iterator, <unresolved overloaded function type>)’
24 | sort(d.begin(), d.end(), sort);
| ^
sort.cpp:6:6: note: candidate: ‘bool sort(std::string, std::string)’
6 | bool sort(string s1, string s2)
| ^~~~
sort.cpp:6:6: note: candidate expects 2 arguments, 3 provided
In file included from /usr/include/c++/9/algorithm:62,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:65,
from sort.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, _RandomAccessIterator __last)
| ^~~~
/usr/include/c++/