Documentation
¶
Overview ¶
Package mathhelper contains math package helpers.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Abs ¶
func Abs[T constraints.Integer | constraints.Float](x T) T
Abs returns the absolute value of 'x'.
func IntMin ¶
func IntMin[T constraints.Integer](m, n T) T
IntMin returns the smaller of 'm' or 'n'.
func Split ¶ added in v0.2.0
func Split[T constraints.Integer](n, parts T) ([]T, error)
Split splits 'n' into 'parts' as equal as possible integer parts. Slice with parts' lengths is returned.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.