3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $a = array('a' => array(0 => 1, 1 => 2) ,'b' => array(0 => 3, 1 => 4)); print_r(array_reduce($a, 'array_merge', $a));
Output for 4.3.0 - 4.3.9, 5.0.0 - 5.0.2, 5.3.0 - 5.6.28, hhvm-3.12.0, 7.0.0 - 7.1.0
Array ( [a] => Array ( [0] => 1 [1] => 2 ) [b] => Array ( [0] => 3 [1] => 4 ) [0] => 1 [1] => 2 [2] => 3 [3] => 4 )
Output for hhvm-3.10.0

Process exited with code 153.
Output for 5.0.3 - 5.2.17
Warning: array_merge(): Argument #1 is not an array in /in/ki2oR on line 3 Warning: array_merge(): Argument #1 is not an array in /in/ki2oR on line 3
Output for 4.3.10 - 4.4.9
Array ( [0] => 1 [1] => 1 [2] => 2 [3] => 3 [4] => 4 )