Method: Array#pop

Defined in:
array.c

#popObject?

Removes the last element from self and returns it, or nil if the array is empty.

a = [ "a", "m", "z" ]
a.pop   #=> "z"
a       #=> ["a", "m"]

Returns:



446
447
448
# File 'array.c', line 446

VALUE
rb_ary_pop(ary)
VALUE ary;