3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $array = array('3' => 2,'1' => 5,'9' => 1); $array_2 = array_reverse($array); print_r($array_2); ?>
Output for 4.3.0 - 7.2.0
Array ( [0] => 1 [1] => 5 [2] => 2 )