Baike.dev
All toolsAI codingTrendingOpen sourceNewsSubmit
Log in
Back to tool/Back to issues
#86·The-Golang-Standard-Library-by-Example

3.1.1 数据集合排序

Author: green961Created Sep 23, 2021Updated Sep 23, 2021

// 如果 i 索引的数据小于 j 索引的数据,返回 true,且不会调用下面的 Swap(),即数据升序排序。 Less(i, j int) bool i 索引是后面的位置, 正是此时调用 Swap

Source: polaris1119/The-Golang-Standard-Library-by-Example

View original on GitHubView discussion on GitHub