Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Example: Result: [9,1] [0,5] [5,2] [2,4] [6,3] [5,2] [2,4] [6,3] [0,5] [9,1]
我知道意义在于比较功能。如何按升序或降序排序。
谢谢。
std::sort从<algorithm>标题使用
std::sort
<algorithm>
您可以使用 lambda 表达式作为比较函数