COHERENT manpages
This page displays the COHERENT manpage for fcvt() [Convert floating-point numbers to strings].
List of available manpages
Index
fcvt() -- General Function (libc) Convert floating-point numbers to strings char * fcvt(d, w, *dp, *signp) double d; int w, *dp, *signp; fcvt() converts floating point numbers to ASCII strings. Its operation resembles that of printf()'s operator %f. fcvt() converts d into a NUL-terminated string of decimal digits. The argument w sets the precision of the string, i.e., the number of characters to the right of the decimal point. fcvt() rounds the last digit and returns a pointer to the result. On return, fcvt() sets dp to point to an integer that indicates the location of the decimal point relative to the beginning of the string: to the right if positive, and to the left if negative. Finally, it sets signp to point to an integer that indicates the sign of d: zero if positive, and nonzero if negative. fcvt() rounds the result to the FORTRAN F-format. Example For an example of this function, see the entry for ecvt(). See Also libc Notes fcvt() performs conversions within static string buffers that it overwrites on each execution.