3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr_1=array(array('name'=>'john','sex'=>'male','grade'=>'9'),array('name'=>'Smith','sex'=>'male','grade'=>'11')); $arr_2=array(array('name'=>'john','sex'=>'male','grade'=>'9'),array('name'=>'Smith','sex'=>'male','grade'=>'11'),array('name'=>'Kelly','sex'=>'female','grade'=>'10')); $c1 = array_map("customImplode",$arr_1); $c2 = array_map("customImplode",$arr_2); function customImplode($data){ return implode("|",$data); } function customExplode($data){ return explode("|",$data); } $result = array_map("customExplode",array_unique(array_merge(array_diff($c1,$c2),array_diff($c2,$c1)))); echo "<pre>"; print_r($result);
Output for git.master, git.master_jit, rfc.property-hooks
<pre>Array ( [0] => Array ( [0] => Kelly [1] => female [2] => 10 ) )

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:
29.64 ms | 405 KiB | 5 Q