3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $a = [1, 2, 3]; $b = [0 => [4], 1 => [5]]; $t = $b[1] + $a; var_dump($t); var_dump(array_merge($a, $b[1]));
based on WLmpb
Output for 5.5.0 - 7.3.0rc3
array(3) { [0]=> int(5) [1]=> int(2) [2]=> int(3) } array(4) { [0]=> int(1) [1]=> int(2) [2]=> int(3) [3]=> int(5) }