AT&T UNIX™PC Unix System V Users Manual - tenox
AT&T UNIX™PC Unix System V Users Manual - tenox AT&T UNIX™PC Unix System V Users Manual - tenox
� --- ·
ECVT (3C) ECVT (3C) NAME ecvt, fcvt, gcvt - convert floating-point number to string SYNOPSIS char •ecvt (value, ndigit, decpt, sign) double value; int ndigit, •decpt, •sign; char •fcvt (value, ndigit, decpt, sign) double value; int ndigit, •decpt, •sign; char •gcvt (value, ndigit, buf) double value; char •buf; DESCRIPTION Ecvt converts value to a null-terminated string of ndigit digits and returns a pointer thereto. The low-order digit is rounded. The position of the decimal point relative to the beginning of the string is stored indirectly through decpt (negative means to the left of the returned digits). The decimal point is not included in the returned string. If the sign of the result is negative, the word pointed to by sign is non-zero, otherwise it is zero. Fcvt is identical to ecvt, except that the correct digit has been rounded for FORTRAN F-format output of the number of digits specified by ndigit . Gcvt converts the value to a null-terminated string in the array pointed to by buf and returns buf. It attempts to produce ndigit significant digits in FORTRAN F-format if possible, otherwise Eformat, ready for printing. A minus sign, if there is one, or a decimal point will be included as part of the returned string. Trailing zeros are suppressed. SEE ALSO printf(3S). BUGS The return values point to static data whose content is overwrit ten by each call. - 1 -
- Page 773 and 774: UMOUNT (2) UMOUNT (2) NAME umount -
- Page 775: UNAME ( 2 ) UNAME (2) NAME uname -
- Page 779: USTAT (2) USTAT (2) NAME ustat - ge
- Page 783 and 784: WAIT ( 2 ) WAIT ( 2 ) NAME wait - w
- Page 785 and 786: WRITE(2) WRITE (2) NAME write - wri
- Page 787 and 788: INTR0 ( 3 ) INTR0 ( 3 ) NAME intro
- Page 789: A64L ( 3C ) A64L ( 3C ) NAME a641,
- Page 793: ABS (3C) ABS (3C) NAME abs - return
- Page 797: ATOF ( 3C ) ATOF ( 3C ) NAME atof -
- Page 800 and 801: ·�
- Page 803: CLOCK( 3C ) CLOCK( 3C ) NAME clock
- Page 806 and 807: J ··- � . ..._ __ .·
- Page 809: CTERMID ( 3S ) CTERMID ( 3S ) NAME
- Page 812 and 813: CTIME (3C) CTIME(3C) The external l
- Page 815 and 816: CURSES ( 3 ) CURSES ( 3 ) NAME curs
- Page 817 and 818: CUSERID ( 3S ) CUSERID ( 3S ) NAME
- Page 819 and 820: DIAL (3C) DIAL(3C) NAME dial - esta
- Page 821 and 822: DRAND48 ( 3C ) DRAND48 ( 3C ) NAME
- Page 823: DRAND48 ( 3C ) DRAND48 ( 3C ) have
- Page 829 and 830: EPRINTF ( 3T ) ( AT&T UNIX PC only
- Page 831 and 832: ERF (3M) ERF (3M) NAME erf1 erfc -
- Page 833: EXP ( 3M ) EXP ( 3M ) NAME exp, log
- Page 837: FERROR (3S) FERROR (3S) NAME ferror
- Page 841 and 842: FOPEN(3S) FOPEN (3S) NAME fopen, fr
- Page 843 and 844: FORM ( 3T ) ( AT&T UNIX PC only ) F
- Page 845 and 846: FORM (3T) (AT&T UNIX PC only ) fiel
- Page 847 and 848: FORM (3T) }; (AT&T UNIX PC only ) F
- Page 849: FREAD ( 3S ) FREAD ( 3S ) NAME frea
- Page 853: FSEEK ( 3S ) FSEEK ( 3S ) NAME fsee
- Page 857 and 858: GAMMA ( 3M ) GAMMA ( 3M ) NAME gamm
- Page 859 and 860: GETC ( 3S ) GETC ( 3S ) NAME getc,
- Page 861: GETCWD ( 3C } GETCWD ( 3C ) NAME ge
- Page 865 and 866: GETGRENT ( 3C ) GETGRENT ( 3C ) NAM
- Page 867: GETLOGIN ( 3C ) GETLOGIN ( 3C ) NAM
- Page 870 and 871: GETOPT (3C) } SEE ALSO getopt(l). e
- Page 873 and 874: GETPENT (3) (AT&T UNIX PC only ) GE
ECVT (3C) ECVT (3C)<br />
NAME<br />
ecvt, fcvt, gcvt - convert floating-point number to string<br />
SYNOPSIS<br />
char •ecvt (value, ndigit, decpt, sign)<br />
double value;<br />
int ndigit, •decpt, •sign;<br />
char •fcvt (value, ndigit, decpt, sign)<br />
double value;<br />
int ndigit, •decpt, •sign;<br />
char •gcvt (value, ndigit, buf)<br />
double value;<br />
char •buf;<br />
DESCRIPTION<br />
Ecvt converts value to a null-terminated string of ndigit digits<br />
and returns a pointer thereto. The low-order digit is rounded.<br />
The position of the decimal point relative to the beginning of the<br />
string is stored indirectly through decpt (negative means to the<br />
left of the returned digits). The decimal point is not included in<br />
the returned string. If the sign of the result is negative, the word<br />
pointed to by sign is non-zero, otherwise it is zero.<br />
Fcvt is identical to ecvt, except that the correct digit has been<br />
rounded for FORTRAN F-format output of the number of digits<br />
specified by ndigit .<br />
Gcvt converts the value to a null-terminated string in the array<br />
pointed to by buf and returns buf. It attempts to produce ndigit<br />
significant digits in FORTRAN F-format if possible, otherwise Eformat,<br />
ready for printing. A minus sign, if there is one, or a<br />
decimal point will be included as part of the returned string.<br />
Trailing zeros are suppressed.<br />
SEE ALSO<br />
printf(3S).<br />
BUGS<br />
The return values point to static data whose content is overwrit<br />
ten by each call.<br />
- 1 -