Finding the lowest value of an array is a pretty common task in PHP, especially when you are dealing with things like scores or money. In the old days before PHP 4, finding the lowest value of an array meant looping through the array and comparing values until you had the lowest one, something like this:
Not too terrible, but definitely not very elegant. Fortunately in PHP 4+ we
min() function available:
Not much to it!