end() advances array's
internal pointer to the last element, and returns the value from
the last element.
<?php
$fruits = array('apple', 'banana', 'cranberry');
print end($fruits); // cranberry
?>
See also current(),
each(),
prev(),
next() and
reset().