Sha256: 021288f34e1691edad29b6b173d36936af9c0fc28d92c555921d718c6e6453c1

Contents?: true

Size: 205 Bytes

Versions: 31

Compression:

Stored size: 205 Bytes

Contents

# frozen_string_literal: true

class RandomGenerator
  KAPA = 3.9 + Random.rand / 10.0

  class << self
    def rand
      @rand ||= Random.rand

      @rand = KAPA * @rand * (1 - @rand)
    end
  end
end

Version data entries

31 entries across 31 versions & 1 rubygems

Version Path
sinclair-2.1.1 spec/support/models/random_generator.rb
sinclair-2.1.0 spec/support/models/random_generator.rb
sinclair-2.0.1 spec/support/models/random_generator.rb
sinclair-2.0.0 spec/support/models/random_generator.rb
sinclair-1.16.3 spec/support/models/random_generator.rb
sinclair-1.16.2 spec/support/models/random_generator.rb
sinclair-1.16.1 spec/support/models/random_generator.rb
sinclair-1.16.0 spec/support/models/random_generator.rb
sinclair-1.15.0 spec/support/models/random_generator.rb
sinclair-1.14.2 spec/support/models/random_generator.rb
sinclair-1.14.1 spec/support/models/random_generator.rb
sinclair-1.14.0 spec/support/models/random_generator.rb
sinclair-1.13.0 spec/support/models/random_generator.rb
sinclair-1.12.1 spec/support/models/random_generator.rb
sinclair-1.12.0 spec/support/models/random_generator.rb
sinclair-1.11.0 spec/support/models/random_generator.rb
sinclair-1.10.0 spec/support/models/random_generator.rb
sinclair-1.9.0 spec/support/models/random_generator.rb
sinclair-1.8.0 spec/support/models/random_generator.rb
sinclair-1.7.0 spec/support/models/random_generator.rb