Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

php get max key in associative array

$array = array(0 => "-1121", 1 => "-1605", 2 => "100", 3 => "55");
echo max(array_keys($array)); ///OUTPUT: 3
Source by tutorialdeep.com #
 
PREVIOUS NEXT
Tagged: #php #max #key #associative #array
ADD COMMENT
Topic
Name
3+1 =