package
0.0.2-migrate-evm
Repository: https://github.com/scalarorg/scalar-core.git
Documentation: pkg.go.dev
# Functions
All tests if all of the elements of the slice match the predicate.
Any tests if any of the elements of the slice match the predicate.
Concat concatenates all given slices.
Distinct returns a new slice where duplicate entries are removed.
Expand creates a slice by executing the generator function count times.
Expand2 creates a slice by executing the generator function count times.
Filter returns a new slice that only contains elements that match the predicate.
FlatMap composes Map and Flatten.
Flatten flattens a slice of slices into a single slice.
ForEach performs the given function on every element of the slice.
GroupBy returns a map with given items each group into a slice.
HasDuplicates returns true if a slice has duplicate entries, false otherwise.
Last returns the last element of a slice, panics if the slice is empty.
Map maps a slice of T to a slice of S.
Reduce performs a reduction to a single value of the source slice according to the given function.
Reverse returns a new slice in which the elements aree listed in reverse order.
ToMap returns a map from the given slice with keys associated by the lookup function.
TryCast tries to cast each element of the slice from type T1 to type T2.
While executes the given function on every element of the slice until the function returns false.