Unix |
Unix v6 |
|
![]() |
atof(3) |
![]() |
atof convert ASCII to floating double atof(nptr)
char *nptr;
converts a string to a floating number. should point to a
string containing the number; the first unrecognized
character ends the number. The only numbers recognized are:
an optional minus sign followed by a string of digits
optionally containing one decimal point, then followed
optionally by the letter e followed by a signed
integer. There are none; overflow results in a very large
number and garbage characters terminate the scan. The
routine should accept initial +, initial blanks, and
E for e. Overflow should be signalled.
![]() |
atof(3) | ![]() |