Flowdock
method

random_number

Importance_1
v2.3.2 - Show latest stable - 0 notes - Class: ActiveSupport::SecureRandom
random_number(n=0) public

SecureRandom.random_number generates a random number.

If an positive integer is given as n, SecureRandom.random_number returns an integer: 0 <= SecureRandom.random_number(n) < n.

If 0 is given or an argument is not given, SecureRandom.random_number returns an float: 0.0 <= SecureRandom.random_number() < 1.0.

Show source
Register or log in to add new notes.