diff --git a/array.c b/array.c index 78eb15054e..ccdcc3d506 100644 --- a/array.c +++ b/array.c @@ -576,9 +576,10 @@ rb_ary_pop(ary) * 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"] + * a = [ "a", "b", "c", "d" ] + * a.pop #=> "d" + * a.pop(2) #=> ["b", "c"] + * a #=> ["a"] */ static VALUE