Skip to end of banner
Go to start of banner

trunc

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 5 Next »

Availability

This routine is available starting with SIL Engine™ 2.5.

Syntax

trunc(number, digits)

Description


Truncates a number to a specified precision.


Parameters

ParameterTypeRequiredDescription
numberNumberYesNumber to truncate.
digitsNumberYesPrecision.

Return type

number


Example

number a = trunc(1.1578212823495777, 3);
print("a= " + a);

Prints: a= 1.157;

See also


  • No labels