https://github.com/golang-infrastructure/go-sleep-sort
睡眠排序
https://github.com/golang-infrastructure/go-sleep-sort
joke sorting-algorithms
Last synced: 3 months ago
JSON representation
睡眠排序
- Host: GitHub
- URL: https://github.com/golang-infrastructure/go-sleep-sort
- Owner: golang-infrastructure
- License: mit
- Created: 2022-12-08T19:31:42.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2022-12-15T15:37:45.000Z (about 3 years ago)
- Last Synced: 2025-01-18T16:11:01.903Z (11 months ago)
- Topics: joke, sorting-algorithms
- Language: Go
- Homepage:
- Size: 3.91 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# 睡眠排序(Sleep Sort)
注意:此项目只是一个玩笑性质的项目,请勿将其用于生产环境!
# 一、安装
```bash
go get -u github.com/golang-infrastructure/go-sleep-sort
```
# 二、示例代码
```go
package main
import (
"fmt"
sleep_sort "github.com/golang-infrastructure/go-sleep-sort"
)
func main() {
slice := []uint{8, 6, 9, 3}
r := sleep_sort.SortUInt(slice)
fmt.Println(r)
// Output:
// [3 6 8 9]
slice = []uint{1000003, 1000010, 1000000}
r = sleep_sort.SortUInt(slice)
fmt.Println(r)
// Output:
// [1000000 1000003 1000010]
}
```