How to merge subarray in PHP most easily?

后端 未结 7 511
渐次进展
渐次进展 2020-12-03 22:32
$arr[] = array(\'A\',\'B\');
$arr[] = array(\'C\',\'B\');
...

I need to get the merged result of all sub array of $arr .

And f

7条回答
  •  -上瘾入骨i
    2020-12-03 23:06

    $merged_array = array_reduce($serp_res, 'array_merge', array()); with added quotas,'array_merge', worked for me.

提交回复
热议问题