3v4l.org

run code in 300+ PHP versions simultaneously
<?php $data = array( 0 => array( 'gozhi' => 2, 'uzorong' => 1, 'ngangla' => 4, 'langthel' => 5 ), 1 => array( 'gozhi' => 5, 'uzorong' => 0, 'ngangla' => 3, 'langthel' => 2 ), 2 => array( 'gozhi' => 3, 'uzorong' => 0, 'ngangla' => 1, 'langthel' => 3 ), ); $res = array_map(function($item) { return array_map(function() { return array_sum(func_get_args()); }, $item); }, $data); var_dump($res);
Output for git.master, git.master_jit, rfc.property-hooks
array(3) { [0]=> array(4) { ["gozhi"]=> int(2) ["uzorong"]=> int(1) ["ngangla"]=> int(4) ["langthel"]=> int(5) } [1]=> array(4) { ["gozhi"]=> int(5) ["uzorong"]=> int(0) ["ngangla"]=> int(3) ["langthel"]=> int(2) } [2]=> array(4) { ["gozhi"]=> int(3) ["uzorong"]=> int(0) ["ngangla"]=> int(1) ["langthel"]=> int(3) } }

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:
40.97 ms | 402 KiB | 8 Q