mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
securerandom.rb: fix an example of choose [ci skip]
* lib/securerandom.rb (Random::Formatter#choose): [DOC] fix an example, `n` is not optional. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60420 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
80f276e16f
commit
7ed3aae2fe
1 changed files with 1 additions and 1 deletions
|
@ -236,7 +236,7 @@ module Random::Formatter
|
|||
#
|
||||
# The result may contain whatever characters are in the source array.
|
||||
#
|
||||
# p SecureRandom.choose([*'l'..'r']) #=> "lmrqpoonmmlqlron"
|
||||
# p SecureRandom.choose([*'l'..'r'], 16) #=> "lmrqpoonmmlqlron"
|
||||
# p SecureRandom.choose([*'0'..'9'], 5) #=> "27309"
|
||||
#
|
||||
# If a secure random number generator is not available,
|
||||
|
|
Loading…
Add table
Reference in a new issue