We haven't covered these yet, but a way to reduce code duplication would be to use a `while` loop, in which case, you could do something like this:

```ruby
guesses_left = 3
while guesses_left > 0
...
end
```