Bug #15948: Basic Subtraction Error
| From: | abuckner at cicadadesign dot com | Date: | Fri, 08 Mar 2002 07:06:02 +0000 |
| Subject: | Bug #15948: Basic Subtraction Error | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-1985@lists.php.net to get a copy of this message | ||
From: abuckner@cicadadesign.com
Operating system: Red Hat Linux 7.1
PHP version: 4.0.6
PHP Bug Type: *Math Functions
Bug description: Basic Subtraction Error
This was submitted by one of our head developers. We're using PHP/MySQL to
build our customer relationship software, and this scares me.
-----------------------
The numbers should add to 0. When I echo the result I get the below:
-5.6843418860808E-14.
<?
echo 241.20 + 169.23 - 410.43;
?>
--
Edit bug report at http://bugs.php.net/?id=15948&edit=1
--
Fixed in CVS: http://bugs.php.net/fix.php?id=15948&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=15948&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=15948&r=needtrace
Try newer version: http://bugs.php.net/fix.php?id=15948&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=15948&r=support
Expected behavior: http://bugs.php.net/fix.php?id=15948&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=15948&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=15948&r=submittedtwice