This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: convert number to string


----- Original Message ----- 
From: "Segher Boessenkool" <segher@kernel.crashing.org>
To: "Tom Tran" <tom.tran@noaa.gov>
Cc: <gcc-help@gcc.gnu.org>
Sent: Thursday, December 18, 2003 11:44 PM
Subject: Re: convert number to string


> > I am trying to convert a number to a string. The C book I have states
> > that the function is in stdlib.h, For example, the syntax for itoa() 
> > is:
> 
> Have a look at sprintf() (or better, snprintf()).
> 
> 
> Segher
> 
> 

You can try strtoul() or strtol().


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]