1234567891011121314151617181920212223242526272829303132333435363738 | '\" t
.\" Copyright (c) 2026 Bruce Hill
.\" All rights reserved.
.\"
.TH Float64.with_precision 3 2026-08-27 "Tomo man-pages"
.SH NAME
Float64.with_precision \- round to a given precision
.SH LIBRARY
Tomo Standard Library
.SH SYNOPSIS
.nf
.BI Float64.with_precision\ :\ func(n:\ Float64,\ precision:\ Float64\ ->\ Float64)
.fi
.SH DESCRIPTION
Round a number to the given precision level (specified as `10`, `.1`, `.001` etc).
.SH ARGUMENTS
.TS
allbox;
lb lb lbx
l l l.
Name Type Description
n Float64 The number to be rounded to a given precision.
precision Float64 The precision to which the number should be rounded.
.TE
.SH RETURN
The number, rounded to the given precision level.
.SH EXAMPLES
.EX
assert Float64(0.1234567).with_precision(0.01) == 0.12
assert Float64(123456.).with_precision(100) == 123500
assert Float64(1234567.).with_precision(5) == 1234565
.EE
.SH SEE ALSO
.BR Tomo-Float64 (3)
|