Documentation ¶
Overview ¶
Package sliceutils provides useful functions for dealing with slices https://gobyexample.com/collection-functions
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Includes ¶
func Includes[T constraints.Ordered](vs []T, t T) bool
Includes returns true if t is contained within vs
func Index ¶
func Index[T constraints.Ordered](vs []T, t T) int
Index returns the first index of t or -1 if no match
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.