$arr[] = array(\'A\',\'B\'); $arr[] = array(\'C\',\'B\'); ...
I need to get the merged result of all sub array of $arr .
$arr
And f
This answer is based on Felix Kling post. It's more accurate version with fixing "non array" sub-elements.
$res = array_reduce($res, function(&$res, $v) { return array_merge($res, (array) $v); }, array());