All Projects → campoy → unique

campoy / unique

Licence: Apache-2.0 license
Package unique provides primitives for sorting slices removing repeated elements.

Programming Languages

go
31211 projects - #10 most used programming language
shell
77523 projects

GoDoc Build Status

unique

Package unique provides primitives for sorting slices removing repeated elements.

a quick example

Executing this code:

	s := []int{3, 5, 1, 7, 2, 3, 7, 5, 2}
	less := func(i, j int) bool { return s[i] < s[j] }
	unique.Slice(&s, less)
	fmt.Println(s)

Will output the following:

[1 2 3 5 7]
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].