Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/EricPengShuai/Interview
/ cmp
Function
cmp
STL/sort1.cpp:7–11 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
5
using namespace std;
6
7
bool cmp(int a, int b)
8
{
9
// return a > b; // 从大到小排序
10
return a < b; // 从小到大排序
11
}
12
13
static bool cmp1(vector<int> a, vector<int> b)
14
{
Callers
nothing calls this directly
Calls
no outgoing calls
Tested by
no test coverage detected