lib/hangman/word.rb
# changes '_' for the corresponding letter if player's guess was correct
changes '_' for the corresponding letter if player's guess was correct
changes ' _ ' for the corresponding letter if player ' s guess was correct
def reveal_letter(letter_guessed)
      @word_selected.split('').each_with_index do |letter, index|
        @hidden_word[index] = letter_guessed if letter_guessed == letter
      end
    end
def reveal_letter ( letter_guessed ) @word_selected . split ( '' ) . each_with_index do | letter , index | @hidden_word [ index ] = letter_guessed if letter_guessed == letter end end
changes '_' for the corresponding letter if player's guess was correct
changes ' _ ' for the corresponding letter if player ' s guess was correct
letter_guessed
<not_specific>