3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr1 = [ 0 => "test zero", 1 => "test one", 2 => "test two", 3 => "test three" ]; $arr2 = [ 1 => "test four", 5 => "test five", 3 => "test six", 4 => "test seven" ]; $i=min(array_keys($arr1)); foreach($arr2 as $k=>$val) { if(array_key_exists($k,$arr1)) { $arr1[$k].='\N, '.$val; } } var_dump($arr1);
Output for git.master, git.master_jit, rfc.property-hooks
array(4) { [0]=> string(9) "test zero" [1]=> string(21) "test one\N, test four" [2]=> string(8) "test two" [3]=> string(22) "test three\N, test six" }

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.69 ms | 401 KiB | 8 Q