Path: utzoo!attcan!uunet!charyb!dan From: dan@kfw.COM (Dan Mick) Newsgroups: comp.lang.c Subject: Re: floating point multiplication BUG in C (cc compiler) Message-ID: <1990Oct20.235102.15882@kfw.COM> Date: 20 Oct 90 23:51:02 GMT References: <1348@banach.ACA.MCC.COM> Reply-To: dan@kfw.com (Dan Mick) Organization: KFW Corporation, Newbury Park, CA Lines: 21 In article <1348@banach.ACA.MCC.COM> mishra@banach.ACA.MCC.COM (Aditya Mishra) writes: >BUG !!! BUG !!! BUG !!! > >THIS PROGRAM DEMONSTRATES WHAT I BELIEVE IS A BUG IN FLOATING POINT >MULTIPLICATION IN 'C' !! Just out of curiosity: Why do you think this is a problem with C? Did it ever occur to you that it might be a problem with floating point on the machine? Did you try it in Pascal, or assembly, or FORTRAN, or as a thought experiment? True, the problems with floating-point math on computers *do* take some time and experience to find, if you've only done string and integer programs before, but have you never tried to add 0.99 and 0.01 on any machine, in any language, before? It's not C's fault. And, by the way: Do you know why it's against the law to yell "FIRE!" in a crowded theater?