|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2001-10-04 05:46 UTC] assid at assid dot com
try out this code <? $a=number_format(200000); $b=number_format(-2000); $c = $a + $b; echo "$$a is $a <BR> \$b is $b <BR> \$c is $c"; ?> isnt it supposed $c supposed to be 198,000 ? PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Wed Oct 29 10:00:01 2025 UTC |
Not a bug When the string "200,000" gets converted to a number when adding, it gets converted to 200 ("," is not a valid char in a number string) Derick