1atof(3)                    Library Functions Manual                    atof(3)
2
3
4

NAME

6       atof - convert a string to a double
7

LIBRARY

9       Standard C library (libc, -lc)
10

SYNOPSIS

12       #include <stdlib.h>
13
14       double atof(const char *nptr);
15

DESCRIPTION

17       The  atof() function converts the initial portion of the string pointed
18       to by nptr to double.  The behavior is the same as
19
20           strtod(nptr, NULL);
21
22       except that atof() does not detect errors.
23

RETURN VALUE

25       The converted value.
26

ATTRIBUTES

28       For an  explanation  of  the  terms  used  in  this  section,  see  at‐
29       tributes(7).
30
31       ┌─────────────────────────────────────┬───────────────┬────────────────┐
32Interface                            Attribute     Value          
33       ├─────────────────────────────────────┼───────────────┼────────────────┤
34atof()                               │ Thread safety │ MT-Safe locale │
35       └─────────────────────────────────────┴───────────────┴────────────────┘
36

STANDARDS

38       C11, POSIX.1-2008.
39

HISTORY

41       POSIX.1-2001, C89, C99, SVr4, 4.3BSD.
42

SEE ALSO

44       atoi(3), atol(3), strfromd(3), strtod(3), strtol(3), strtoul(3)
45
46
47
48Linux man-pages 6.05              2023-07-20                           atof(3)
Impressum