Sha256: df35459b9f63105bebb38233a5987d7f273f6ec684222b0bd3406a0bd6ad4714

Contents?: true

Size: 406 Bytes

Versions: 11

Compression:

Stored size: 406 Bytes

Contents

module AlexCodebreaker
  class SecretCodeGenerator
    attr_reader :secret_code

    def initialize
      @secret_code = generate_secret_code
    end

    private

    def generate_secret_code
      Array.new(AlexCodebreaker::Modules::Settings::CODE_LENGTH) do
        rand(AlexCodebreaker::Modules::Settings::CODE_MIN_DIGIT..AlexCodebreaker::Modules::Settings::CODE_MAX_DIGIT)
      end
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
alex_codebreaker-0.2.3 lib/alex_codebreaker/secret_code_generator.rb
alex_codebreaker-0.2.2 lib/alex_codebreaker/secret_code_generator.rb
alex_codebreaker-0.2.1 lib/alex_codebreaker/secret_code_generator.rb
alex_codebreaker-0.2.0 lib/alex_codebreaker/secret_code_generator.rb
alex_codebreaker-0.1.13 lib/alex_codebreaker/secret_code_generator.rb
alex_codebreaker-0.1.12 lib/alex_codebreaker/secret_code_generator.rb
alex_codebreaker-0.1.11 lib/alex_codebreaker/secret_code_generator.rb
alex_codebreaker-0.1.10 lib/alex_codebreaker/secret_code_generator.rb
alex_codebreaker-0.1.9 lib/alex_codebreaker/secret_code_generator.rb
alex_codebreaker-0.1.8 lib/alex_codebreaker/secret_code_generator.rb
alex_codebreaker-0.1.7 lib/alex_codebreaker/secret_code_generator.rb