I don't want to ruin the challenge for you but if you would like you can take a look at my java hangman example...
http://www.javaprogrammingforums.com...a-hangman.html however keep in mind that I am a beginner here as well but I did manage to get that part of my program to work just fine using a StringBuilder. This allowed me to modify a string where as a String is immutable.
String word = "";
for(int i = 0; i < secret.length(); i++){ // display dashes for length of word
word += "-";
}
StringBuilder guessedWord = new StringBuilder(word);
System.out.println(guessedWord); // print number of dashes for word
for(int i = 0; i < guessedWord.length(); i++){ // check for letter in word
if(guess == secret.charAt(i)){
guessedWord.setCharAt(i, guess);
}
}//end for