Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MergeSortFunc ¶
func MergeSortFunc(data []interface{}, ascend bool, greaterThan func(interface{}, interface{}) bool) []interface{}
MergeSortFunc 归并排序,任意类型自定义升降序,需要传入大于判断函数实现。修改原数组,稳定排序。
func MergeSortIntCopy ¶
MergeSortIntCopy 归并排序,整型数组可用,深拷贝不影响原数组,稳定升序。
func QuickSortFunc ¶
func QuickSortFunc(data []interface{}, ascend bool, greaterThan func(interface{}, interface{}) bool) []interface{}
QuickSortFunc 快速排序,任意类型自定升降序,需要传入大于函数实现,修改至原数组。
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.