Source Code:
(back to article)
<?php $fruits = ['apple' => 'red', 'banana' => 'yellow', 'orange' => 'orange']; $keys = array_keys($fruits); print_r($keys); // outputs: Array ( [0] => apple [1] => banana [2] => orange )
Result:
Report an issue