#31018 [NEW]: all
| From: | Fox235 at yandex dot ru | Date: | Wed, 08 Dec 2004 11:02:31 +0000 |
| Subject: | #31018 [NEW]: all | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-69921@lists.php.net to get a copy of this message | ||
From: Fox235 at yandex dot ru
Operating system: Linux
PHP version: 4.3.9
PHP Bug Type: Unknown/Other Function
Bug description: all
Description:
------------
not 1!But it's must = 1
Reproduce code:
---------------
$a=split(';' , $Ver);
rsort($a);
print_r($a);
$S = array_sum($a);
$f=floatval($S);
if ($f == 1)
{ echo "Yes, it's 1";
}
else
{ echo "<br>Not, it's not 1";}
?>
Expected result:
----------------
Array ( [0] => 0.5 [1] => 0.2 [2] => 0.1 [3] => 0.1 [4] => 0.1 )
Yes, it's 1
Actual result:
--------------
Array ( [0] => 0.5 [1] => 0.2 [2] => 0.1 [3] => 0.1 [4] => 0.1 )
Not, it's not 1
--
Edit bug report at http://bugs.php.net/?id=31018&edit=1
--
Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=31018&r=trysnapshot4
Try a CVS snapshot (php5.0): http://bugs.php.net/fix.php?id=31018&r=trysnapshot50
Try a CVS snapshot (php5.1): http://bugs.php.net/fix.php?id=31018&r=trysnapshot51
Fixed in CVS: http://bugs.php.net/fix.php?id=31018&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=31018&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=31018&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=31018&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=31018&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=31018&r=support
Expected behavior: http://bugs.php.net/fix.php?id=31018&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=31018&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=31018&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=31018&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=31018&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=31018&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=31018&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=31018&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=31018&r=float
MySQL Configuration Error: http://bugs.php.net/fix.php?id=31018&r=mysqlcfg