3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $foo = array("123", "0124", "125", "0"); natsort($foo); var_dump($foo);
Output for 5.2.10 - 5.6.28, 7.0.0 - 7.1.0
array(4) { [3]=> string(1) "0" [0]=> string(3) "123" [1]=> string(4) "0124" [2]=> string(3) "125" }
Output for 4.3.0 - 5.2.9, hhvm-3.10.0 - 3.12.0
array(4) { [3]=> string(1) "0" [1]=> string(4) "0124" [0]=> string(3) "123" [2]=> string(3) "125" }