Basic30 Language Reference
Float Function |
Returns a number as a Single type value.
- expression
- Required. A number or numeric expression
Requirements
- This function requires the link time library "libm.a".
It is a free download from the Microchip website.
- The flie <libs/math.bas> must be included in the
Basic source to use this function.
Example
#include <libs/math.bas>
Dim a as Single
Dim i as Long
i=543
a=Float(i) ' a is now 543.0
Also See: Int