Awhuxlb.206 net.micro utzoo!decvax!harpo!zeppo!whuxlb!mkg Wed Apr 7 23:44:33 1982 IBM PC divide bug revisited Having access to an IBM PC, I couldn't resist trying to make the .1/10 giving .001 bug happen. After many tries, I discovered that as long as the division is done with variables, the result is ok. To successfully cause the "bug", I had to do the division using double precision literals (print .1#/10#). Unfortunately, I don't think the bug is in the output routine as was earlier suspected. The following program also fails!! c#=.1#/10# print c# Maybe IBM will handle this the way they sometimes "fix" bugs on their large systems... They'll change the manual and call it a "feature". Oh yes, one other thing. Did you know that .1#/100# == .1#/1000#? They both yield .0001. Marsh Gosnell BTL Piscataway (...!whuxlb!pyuxr!mkg) ----------------------------------------------------------------- gopher://quux.org/ conversion by John Goerzen of http://communication.ucsd.edu/A-News/ This Usenet Oldnews Archive article may be copied and distributed freely, provided: 1. There is no money collected for the text(s) of the articles. 2. The following notice remains appended to each copy: The Usenet Oldnews Archive: Compilation Copyright (C) 1981, 1996 Bruce Jones, Henry Spencer, David Wiseman.