Skip to content
Chris Petersen edited this page Oct 16, 2014 · 1 revision

fix changes a number to a fixed point value. This function is used throughout to prevent exactness errors and always returns the value closest to zero!

Parameter Description
n Number to be converted

Example

Example 1: Convert some numbers using fix.

> (fix 0.4)
0
> (fix 0.99)
0
> (fix -1.99)
-1
Clone this wiki locally