HTML Utilities

Showing help on 'floatstr()'

Syntax: floatstr (FLOAT x, INT precision [, scientific]) => STR

Converts <x> into a string with more control than provided by either `tostr()' or `toliteral()'. <Precision> is the number of digits to appear to the right of the decimal point, capped at 4 more than the maximum available precision, a total of 19 on most machines; this makes it possible to avoid rounding errors if the resulting string is subsequently read back as a floating-point value. If <scientific> is false or not provided, the result is a string in the form "MMMMMMM.DDDDDD", preceded by a minus sign if and only if <x> is negative. If <scientific> is provided and true, the result is a string in the form "M.DDDDDDe+EEE", again preceded by a minus sign if and only if <x> is negative.



-- telnet://project-mongoose.net:7777 -- Mail us -- http://project-mongoose.net:7780/ --
-- Five users connected --