Perl 5 version 8.9 documentation
Pops and returns the last value of the array, shortening the array by one element.
If there are no elements in the array, returns the undefined value (although this may happen at other times as well). If ARRAY is omitted, pops the
@ARGVarray in the main program, and the
@_array in subroutines, just like