modf
modf floatValue
The integer part and the fraction part of a double, as a list. Both parts have the sign of the value.
Examples
modf 2.5gives2.0 0.5modf -2.5gives-2.0 -0.5
Facts
- Capability: none.
- Compute cost: one compute unit for the call, and more for the commands that it runs.
- Release: Tcl 9.1 only. A script has the command when ztcl follows Tcl 9.1, with
--tcl 9.1. See Tcl 9.1.