note 72974 deleted from ref.array by felipe
| Newsgroups | php.notes |
|---|---|
| Message-ID | <[email protected]> |
Note Submitter: hannes dot dahlberg at gmail dot com
----
A small function to get the median of an array filled with numbers
function median($array)
{
sort($array);
return ($array[ceil((count($array) / 2)) - 1] + $array[floor((count($array) / 2))]) / 2;
}