Registry / utility / rwxrob-fn

rwxrob-fn

JSON →
library0.4.0gogounverified

Package fn implements traditional map/filter/reduce/each functions and an array type (A) for Go.

go get github.com/rwxrob/fn
INSTALL
IMPORT
SIG · RWXROB-FN
R
rwxrob-fn
utilitygov0.4.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

fn
github.com/rwxrob/fn

Use the A type to map over a slice and double each element.

package main import ( "fmt" "github.com/rwxrob/fn" ) func main() { data := fn.A{1, 2, 3, 4, 5} doubled := data.Map(func(x interface{}) interface{} { return x.(int) * 2 }) fmt.Println(doubled) }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
0.4.0latest on pkg.go.dev
Audit
Dependencies

No dependency data recorded yet.

Agent activity
4 hits · last 30 days
node
4
Resources
rwxrob-fn — go get rwxrob-fn · libregistry