| delorie.com/archives/browse.cgi | search |
| From: | mert0407 AT sable DOT ox DOT ac DOT uk (George Foot) |
| Newsgroups: | comp.lang.c,comp.os.msdos.djgpp |
| Subject: | Re: having trouble with long numbers |
| Followup-To: | comp.lang.c,comp.os.msdos.djgpp |
| Date: | 29 Jul 1997 23:45:35 GMT |
| Organization: | Oxford University, England |
| Lines: | 15 |
| Message-ID: | <5rlvav$101@news.ox.ac.uk> |
| References: | <01bc9c51$0ceeec80$78ed1fcc AT darkstar> <33DE6FA3 DOT 460B59E AT voyager DOT net> |
| NNTP-Posting-Host: | sable.ox.ac.uk |
| To: | djgpp AT delorie DOT com |
| DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
Mark Levis (mlevis AT voyager DOT net) wrote: : Use a double. It will have precision up to 14 digits. An int will only : handle number from : -32767 to 32768. : unsigned int 0 65535 That's compiler dependent; since this was cross-posted to comp.os.msdos.djgpp I assume the compiler in question is the gcc with djgpp, which uses 32-bit ints by default, not 16-bit. The range is about four (American) billion I believe. -- George Foot <mert0407 AT sable DOT ox DOT ac DOT uk> Merton College, Oxford
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |