www.delorie.com/djgpp/doc/libc/libc_786.html   search  
libc.a reference

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

strtoumax

Syntax

 
#include <inttypes.h>

uintmax_t strtoumax (const char *s, char **endp, int base);

Description

This is just like strtoimax (see section strtoimax) except that the result is unsigned.

Return Value

The value.

Portability

ANSI/ISO C C99; not C89
POSIX 1003.1-2001; not 1003.2-1992

Example

 
printf("Enter a number: "); fflush(stdout);
gets(buf);
char *bp;
printf("The value is %" PRIuMAX "\n", strtoumax(buf, &bp, 0));

  webmaster   donations   bookstore     delorie software   privacy  
  Copyright 2004   by DJ Delorie     Updated Apr 2004