Commit 2960c694 authored by Yukihiro "Matz" Matsumoto's avatar Yukihiro "Matz" Matsumoto Committed by GitHub

Merge pull request #3232 from lukaselmer/patch-1

Update documentation of fetch
parents cc3f1b7f f02694ec
......@@ -275,8 +275,9 @@ class Array
# +default+ value.
#
# Alternatively, if a block is given it will only be executed when an
# invalid +index+ is referenced. Negative values of +index+ count from the
# end of the array.
# invalid +index+ is referenced.
#
# Negative values of +index+ count from the end of the array.
#
# a = [ 11, 22, 33, 44 ]
# a.fetch(1) #=> 22
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment