| delorie.com/archives/browse.cgi | search |
| Date: | Wed, 30 Aug 2000 14:18:37 +0200 (MET DST) |
| From: | pad2369 <pad2369 AT iperbole DOT bologna DOT it> |
| Message-Id: | <200008301218.OAA20244@maggiore.iperbole.bologna.it> |
| To: | djgpp AT delorie DOT com, Chris Amos <homie_dont_play_dat AT yahoo DOT com> |
| References: | <20000830103233 DOT 2091 DOT qmail AT web509 DOT mail DOT yahoo DOT com> |
| In-Reply-To: | <20000830103233.2091.qmail@web509.mail.yahoo.com> |
| MIME-Version: | 1.0 |
| User-Agent: | IMP/PHP3 Imap webMail Program 2.0.11 |
| Sender: | pad2369 AT iperbole DOT bologna DOT it |
| Subject: | Re: Newbie here: How do i convert a number to a string? |
| Reply-To: | djgpp AT delorie DOT com |
Chris Amos <homie_dont_play_dat AT yahoo DOT com>: > I have looked though my c books but i think there is > no ansi standard > way of doing that and thats why i couldnt find > anything. I looked in I use sprintf (both ANSI and POSIX) for this, like in: /* untested */ char buf[MAXBUF]; sprintf( buf, "%5.2f", 123.45678 ); ciao Giacomo ---------------------------------------------------- Giacomo Degli Esposti - pad2369 AT iperbole DOT bologna DOT it
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |