ID: 35442
Updated by: [EMAIL PROTECTED]
Reported By: yag_kawa at yahoo dot co dot jp
-Status: Open
+Status: Bogus
Bug Type: Variables related
Operating System: Linux
PHP Version: 5.1.0
New Comment:
printf() doesn't *round* anything.
Use round() for that.
Previous Comments:
------------------------------------------------------------------------
[2005-11-28 12:26:20] yag_kawa at yahoo dot co dot jp
Description:
------------
printf %f rounding error
Reproduce code:
---------------
<?php
$a=43.65;
printf("%6.1f",$s);
?>
Expected result:
----------------
43.6
Actual result:
--------------
43.7
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=35442&edit=1