3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $a1 = array( 'apple'=>1,'banana'=>2,'coconut'=> 3); $a2 = array( 'apple'=>2,'banana'=>3,'coconut'=> 4); echo "<pre>"; print_r(array_merge_recursive($a1,$a2)); echo "</pre>";
Output for 4.3.0 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
<pre>Array ( [apple] => Array ( [0] => 1 [1] => 2 ) [banana] => Array ( [0] => 2 [1] => 3 ) [coconut] => Array ( [0] => 3 [1] => 4 ) ) </pre>