lib/codebreaker/game.rb in codebreaker_z-1.0.0 vs lib/codebreaker/game.rb in codebreaker_z-1.1.0

- old
+ new

@@ -8,9 +8,17 @@ @attempt = 0 @hint = 0 @is_winner = false end + def attempts_left + ATTEMPTS_COUNT - @attempt + end + + def hints_left + HINTS_COUNT - @hint + end + def generate_code @secret_code = Array.new(4){ rand(6) + 1 }.join end def guess(input)