strtod - STRTOD(3) Library functions STRTOD(3) NAME strtod,...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: STRTOD(3) Library functions STRTOD(3) NAME strtod, strtof, strtold - convert ASCII string to floating point number SYNOPSIS #include <stdlib.h> double strtod(const char * nptr , char ** endptr ); float strtof(const char * nptr , char ** endptr ); long double strtold(const char * nptr , char ** endptr ); DESCRIPTION The strtod , strtof , and strtold functions convert the initial portion of the string pointed to by nptr to dou- ble , float , and long double representation, respectively. The expected form of the (initial portion of the) string is optional leading white space as recognized by is- space (3), an optional plus (‘‘+’’) or minus sign (‘‘-’’) and then either (i) a decimal number, or (ii) a hexa- decimal number, or (iii) an infinity, or (iv) a NAN (not-a-number). A decimal number consists of a nonempty sequence of decimal digits possibly containing a radix character (decimal point, locale dependent, usually ‘‘.’’), optionally followed by a decimal exponent. A decimal(decimal point, locale dependent, usually ‘‘....
View Full Document

This note was uploaded on 10/05/2009 for the course COMP 2510 taught by Professor A during the Spring '06 term at BC.

Ask a homework question - tutors are online