php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #10727 print((2.3 * 100 % 100) . "<br>\n"); does not print 30 but 29
Submitted: 2001-05-08 06:24 UTC Modified: 2001-05-08 06:38 UTC
From: d dot peereboom-voller at nl dot worldonline dot com Assigned:
Status: Not a bug Package: Math related
PHP Version: 4.0.4pl1 OS: Linux
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: d dot peereboom-voller at nl dot worldonline dot com
New email:
PHP Version: OS:

 

 [2001-05-08 06:24 UTC] d dot peereboom-voller at nl dot worldonline dot com
print((2.3 * 100 % 100) . "<br>\n");
This generated 29 
while 
print((230 % 100) . "<br>\n");
writes 30 as expected


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-05-08 06:38 UTC] hholzgra@php.net
this is a general problem with decimal
calculations on binary processors
and not related to php itself
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Oct 31 23:01:28 2024 UTC