floatsutils

package
v0.414.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 28, 2025 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MustRound

func MustRound(input float64, nDigits int) (rounded float64)

func MustToString

func MustToString(input float64, maxDigits int) (formatedFloat string)

func Round

func Round(input float64, nDigits int) (rounded float64, err error)

func ToString

func ToString(input float64, maxDigits int) (formatedFloat string, err error)

Format the given float64 'input' as string with 'maxDigits' digits after the '.'. Tailing zeros after '.' are removed.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL