3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $a = array(1=>'a', 'a' => 'b', 'a' => 'b'); //unset($a[4]); //unset($a[5]); ///$a[4] = 'clement'; // //array_push($a, 'c'); array_unshift($a, '1'); var_dump($a);
based on Bklj1
Output for 4.3.0 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
array(3) { [0]=> string(1) "1" [1]=> string(1) "a" ["a"]=> string(1) "b" }