Class: Put::PutsThing::Anywhere

Inherits:
Put::PutsThing show all
Defined in:
lib/put/puts_thing/anywhere.rb

Instance Method Summary collapse

Methods inherited from Put::PutsThing

#<=>, #nils_first?, #reverse?

Constructor Details

#initialize(seed) ⇒ Anywhere

Returns a new instance of Anywhere.



4
5
6
# File 'lib/put/puts_thing/anywhere.rb', line 4

def initialize(seed)
  @random = seed.nil? ? Random.new : Random.new(seed)
end

Instance Method Details

#valueObject



8
9
10
# File 'lib/put/puts_thing/anywhere.rb', line 8

def value
  @random.rand
end