$last_index = array_keys($array);
rsort($last_index);
$last_index = $last_index[0];
echo 'Last index is: ' . $last_index;
NOTE: This doesn't actually check to see if $array[k][0] exists... it just tells you the highest index k that exists in the array. If you want to literally check that the value of this highest k is actually an array itself that contains a 0 key, you could do this:
$last_index = array_keys($array);
rsort($last_index);
for($i = 0; isset($last_index[$i]); $i++) {
if(isset($array[($last_index[$i])][0])) {
$last_index = $last_index[$i];
break;
}
}
echo 'Last index is: ' . $last_index;