package
0.3.0
Repository: https://github.com/mikehelmick/go-functional.git
Documentation: pkg.go.dev

# Functions

All returns true if all elements in the input slice are true according to the provided matchFn.
Any returns true if any of the elements in the input slice return true when the provided matchFn is called.
Filter returns a new slice of only the elements in the list that match the provided matchFn.
FoldL folds (reduces) the input slice from the left.
FoldR folds (reduces) the input slice from the right.
Frequencies returns a map with a count of the number of time each element occurs in the input slice.
FrequenciesBy returns a map with a count of the number of times each key occurred in the input sequence.
GroupBy groups the input slice according to the key function.
Map takes in a slice of type T, and a map function that can turn elements of type T into elements of type R.
MapToPtr transforms a slice into a slice of pointers to the same elements.
Take returns an amount of elements from the beginning of a slice.
TakeEvery returns a new slice with every nth element from the original slice.
TakeWhile returns elements from the beginning of the input slice as long as the provided MatchFn returns true.

# Type aliases

AccFn is the type of the accumulator function, used on various fold operations.
KeyFn determines how the input value should be used when determining frequencies.
MapFn maps an individual instance of a type T into an individual instance of type R.
MatchFn indicates if an element of a slice matches the inclusion function.