home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / os / msdos / programm / 11560 < prev    next >
Encoding:
Internet Message Format  |  1992-12-22  |  1.0 KB

  1. Path: sparky!uunet!zaphod.mps.ohio-state.edu!darwin.sura.net!jvnc.net!yale.edu!qt.cs.utexas.edu!cs.utexas.edu!sun-barr!olivea!hal.com!darkstar.UCSC.EDU!cats.ucsc.edu!spencer
  2. From: spencer@cats.ucsc.edu (Michael Spencer)
  3. Newsgroups: comp.os.msdos.programmer
  4. Subject: Re: Math error in BC++? Help!
  5. Message-ID: <1h5akvINNso4@darkstar.UCSC.EDU>
  6. Date: 21 Dec 92 20:49:35 GMT
  7. References: <1992Dec15.211516.1664@schunix.uucp>
  8. Distribution: na
  9. Organization: University of California, Santa Cruz
  10. Lines: 17
  11. NNTP-Posting-Host: si.ucsc.edu
  12.  
  13.  
  14. sonix@schunix.uucp (Duane Morin) writes:
  15.  
  16. >This is driving us NUTS!! Will someone please take a look at the following 
  17. >code and see if they can figure out why it does what it does?  Thank you.
  18.  
  19. >// This next one is our error:
  20. >#define ILOGN(y) (int) (log ((double)y) / LOG2 )
  21. ==============================================================
  22.  
  23. The problem may be with the spacing on your define, try:
  24.  
  25. #define ILOGN(y) ((int)(log ((double)y) / LOG2 ))
  26.  
  27.                 Good luck
  28.                     Mike Spencer
  29.                     spencer@cats.ucsc.edu
  30.