3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array1 = array("id1" => "value1","id3" => "value6"); $array2 = array("id2" => "value2", "id3" => "value3", "id4" => "value4"); $array3 = array_merge($array2, $array1/*, $arrayN, $arrayN*/); $array4 = $array1 + $array2; echo '<pre>'; var_dump($array3); var_dump($array4); echo '</pre>';
Output for git.master, git.master_jit, rfc.property-hooks
<pre>array(4) { ["id2"]=> string(6) "value2" ["id3"]=> string(6) "value6" ["id4"]=> string(6) "value4" ["id1"]=> string(6) "value1" } array(4) { ["id1"]=> string(6) "value1" ["id3"]=> string(6) "value6" ["id2"]=> string(6) "value2" ["id4"]=> string(6) "value4" } </pre>

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
41.66 ms | 402 KiB | 8 Q