home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / lang / c / 12650 < prev    next >
Encoding:
Text File  |  1992-08-22  |  939 b   |  27 lines

  1. Newsgroups: comp.lang.c
  2. Path: sparky!uunet!cs.utexas.edu!torn!utzoo!telly!druid!darcy
  3. From: darcy@druid.uucp (D'Arcy J.M. Cain)
  4. Subject: Re: problems with atof() 
  5. Message-ID: <1992Aug22.075915.3990@druid.uucp>
  6. Date: Sat, 22 Aug 1992 07:59:15 GMT
  7. References: <1992Aug20.125252.3451@dxcern.cern.ch>
  8. Organization: D'Arcy Cain Consulting
  9. Lines: 16
  10.  
  11. nilo@atdigarfield.cern.ch (Operator) writes:
  12. > I have a problem withe the atof() function, you know string to double 
  13. >conversion. 
  14. > [...]
  15. >    #include <stdio.h>
  16. >    #include <ctype.h>
  17.  
  18. Where's stdlib.h?  Without it your compiler thinks that atof returns an
  19. int and does an int to float conversion on the float that atof returns.
  20. If your compiler doesn't have a stdlib.h then try math.h.
  21.  
  22. -- 
  23. D'Arcy J.M. Cain (darcy@druid.com)  |
  24. D'Arcy Cain Consulting              |   There's no government
  25. Toronto, Ontario, Canada            |   like no government!
  26. +1 416 424 2871          DoD#0082   |
  27.