Hi, On 08.02.16 18:06, Cesar Rodas wrote: >>> return array_keys($arr) !== range(0, count($arr) - 1); > > `array_keys($array) === range(0, count($array)-1)`
That approach would fall flat when the numeric keys are not consecutive: $array = [1=>"a", 3=>"b"]; Disclaimer: AFAIK complete goal of the function wasn't yet stated, thus this could be considered /acceptable/. cheers, - Markus -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php