Hi I am working on some array operations.
I need to convert first value of array as key and second value of array as value.
I have one variable $test
Simple solution using array_map function:
$result = array_map(function($v){ return [$v[0] => $v[1]]; }, $testArray);