3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $max = 1; for ($i = 0; $i < $max; $i += 0.1) { var_dump("$i < $max"); }
Output for 4.3.0 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
string(5) "0 < 1" string(7) "0.1 < 1" string(7) "0.2 < 1" string(7) "0.3 < 1" string(7) "0.4 < 1" string(7) "0.5 < 1" string(7) "0.6 < 1" string(7) "0.7 < 1" string(7) "0.8 < 1" string(7) "0.9 < 1" string(5) "1 < 1"