Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
to my shock & dismay, $diff ended up with the value '-4.65661287307739e-010'. I ran the same code in a test perl script to maintain my level of sanity.#x & y are both -3809482.42154223 my $diff = abs( $x - $y );
and lo and behold, $diff ended up to be zero. What is going on? Any clues? thanks, Michaelmy $x='-3809482.42154223'; my $y='-3809482.42154223'; my $diff = abs( $x - $y ); print $diff, "\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: weird excel problem
by fglock (Vicar) on Oct 04, 2002 at 16:37 UTC | |
|
Re: weird excel problem
by RMGir (Prior) on Oct 04, 2002 at 16:39 UTC | |
|
Re: weird excel problem
by jmcnamara (Monsignor) on Oct 04, 2002 at 21:55 UTC |