Documentation ¶
Index ¶
- func Columns[T any, K any](l []T, f func(T) K) []K
- func Contains[T comparable](l []T, target T) bool
- func Distinct[T comparable](list []T) []T
- func FirstEle[T any](list []T) T
- func HasEmpty[T comparable](list []T) bool
- func IntsToStrings[K constraints.Integer](l []K) []string
- func Merge[T constraints.Ordered](origin, target []T) []T
- func Reverse[T any](nums []T)
- func Split[T any](list []T, size int) [][]T
- func StringsToInts[T constraints.Integer](list []string) []T
- func StrsContains[K ~string](l []K, target K) bool
- func ToSet[T comparable](l []T) map[T]struct{}
- func ToSetFunc[T comparable, V any](l []any, f func(in any) (key T, value V)) map[T]V
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Contains ¶
func Contains[T comparable](l []T, target T) bool
func Distinct ¶
func Distinct[T comparable](list []T) []T
func HasEmpty ¶
func HasEmpty[T comparable](list []T) bool
func IntsToStrings ¶
func IntsToStrings[K constraints.Integer](l []K) []string
func Merge ¶
func Merge[T constraints.Ordered](origin, target []T) []T
func StringsToInts ¶
func StringsToInts[T constraints.Integer](list []string) []T
func StrsContains ¶
func ToSet ¶
func ToSet[T comparable](l []T) map[T]struct{}
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.