public void GuessLetter(char letter) { if (!Word.Contains(letter)) { Lives--; } else { int index = Word.IndexOf(letter); while (index != -1) { var sb = new StringBuilder(RevealedLetters); sb[index] = letter; ValidateInput(letter); RevealedLetters = sb.ToString(); index = Word.IndexOf(letter, index + 1); } } }