3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $a = 4121.57;$b = 3998;$c = 123.57;$d = round( $a - $b - $c, 2);$e = round( $d, 2 );$f = e === 0; echo "\n";echo str_pad(print_r($d,TRUE),4,' ')." // NEGATIVE ZERO?"."\n";echo str_pad(print_r($e,TRUE),4,' ')." // Don't worry, it rounds to zero! -_-"."\n";var_dump($f);
based on WPD3U
Output for 4.3.0 - 5.2.6, 5.3.0 - 7.1.0
Notice: Use of undefined constant e - assumed 'e' in /in/ZiBGg on line 1 -0 // NEGATIVE ZERO? 0 // Don't worry, it rounds to zero! -_- bool(false)
Output for 5.2.7 - 5.2.17
Notice: Use of undefined constant e - assumed 'e' in /in/ZiBGg on line 1 -0 // NEGATIVE ZERO? -0 // Don't worry, it rounds to zero! -_- bool(false)