Removes the last element from @array and returns it.
@array - the array to "pop" a value from.
The scalar removed from the end of the specified array.
@stack = @("bottom", "middle", "top"); $top = pop(@stack); println($top); println("Stack is: " . @stack);
top Stack is: @('bottom', 'middle')