Copy Code code as follows:
<?php
/* Function Array_pop (): Eject the last cell of the array (out of stack)
* 1, Syntax: Mixed array_pop (array &array)
* 2. Description: pops up and returns the last cell of the array, minus one of the array lengths. If the array is empty (or not an array), it returns NULL.
* 3, the attention matters:
* 3.1,
*/
echo "***********************************************************************<br>";
$arr 11=array (' score 1 ' =>65, ' score 2 ' =>25, ' score 3 ' =>87, ' score 4 ' =>85, ' score 5 ' =>45, ' score 6 ' =>66);
$arr 22=array (a,b,c,d,e);
echo "Array arr11 information:";
echo "<pre>";
Print_r ($arr 11);
echo "</pre>";
$num =count ($arr 11);
for ($i =0; $i < $num; $i + +) {
echo "The last element of the array that pops up is:". Array_pop ($arr 11). <br/> ";
echo "Each time a last element pops up, the array arr11 the information:";
echo "<pre>";
Print_r ($arr 11);
echo "</pre>";
echo "<br/>";
}
?>