133982cfaf
Composicion: Pipe2, Pipe3, Compose2, Identity, Curry2, Uncurry2, Partial2, Flip, Const. Slices: Find, FindIndex, Any, All, GroupBy, Flatten, FlatMapSlice, Unique, Zip, Reduce, Take, Drop. Stubs que documentan devfactory/core para el registry.
565 B
565 B
name, kind, lang, domain, version, purity, signature, description, tags, uses_functions, uses_types, returns, returns_optional, error_type, imports, tested, tests, test_file_path, file_path
| name | kind | lang | domain | version | purity | signature | description | tags | uses_functions | uses_types | returns | returns_optional | error_type | imports | tested | tests | test_file_path | file_path | |||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| take | function | go | core | 1.0.0 | pure | func Take[T any](slice []T, n int) []T | Devuelve los primeros n elementos de un slice. |
|
false | false | functions/core/take.go |
Ejemplo
result := Take([]int{1, 2, 3, 4, 5}, 3)
// result = [1, 2, 3]
Notas
Funcion pura generica. Implementacion en devfactory/core.