package
Version:
v0.0.0-...-c5e7dcc
Opens a new window with list of versions in this module.
Published: Sep 3, 2022
License: MIT
Opens a new window with license information.
Imports: 0
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
func BubbleSort(list []int)
BubbleSort 冒泡排序(相邻两个元素依次比较大小交换,第一和第二比较,第二和第三比较,依次类推)
func InsertSort(list []int)
InsertSort 直接插入排序:每一轮取一个元素插入到该元素左边的有序列表形成新的有序列表
func QuickSort(list []int, start, end int)
func SelectGoodSort(list []int)
SelectGoodSort 优化后的选择排序,每轮同时找最大值和最小值
func SelectSort(list []int)
SelectSort 选择排序(遍历数组,每次找到最小值放到前面)
func ShellSort(list []int)
ShellSort 希尔排序:直接插入排序的改进版,通过多次分组进行插入排序
Source Files
¶
Click to show internal directories.
Click to hide internal directories.