Here is my array:
Array
(
[0] => Array
(
[0] => Array
(
[0] => West
[1] => 4
)
[1] => Array
(
[0] => South west
[1] => 20
)
)
)
What I want to achieve is be able to compare $array[0][0][1] and $array[0][1][1]. So whichever is lesser comes first and I get the value. So in this case I know that 4 is lesser so I get West first then South west is next. It should be dynamic since we can get more than 2.
$array)? Or the array in the middle ($array[0])?