Sigh, I retried the entire code but I am uncertain about the section of checking for a match and getting the random word is still confusing. :(
import java.util.*;
public class Test3 {...
Type: Posts; User: Java girl
Sigh, I retried the entire code but I am uncertain about the section of checking for a match and getting the random word is still confusing. :(
import java.util.*;
public class Test3 {...
I am having a lot of difficulties so I attempted to get away to find the random number:
strWordArray = new String[10];
for (int i = 0; i < strWordArray.length; i++) {
...
Sorry, not done yet, am actually multitasking with another assignment due tonight. Will upload as soon as am finished.
I have to read the words from the file and output it onscreen
Currently we only use scanner in class. I will read through the links and take all ur points into consideration to alter my current code. Will re-upload in an hour
1. In the file, each word is placed on a newline.
2. No specified number of words were given.
3. Yes there is a file reading, I see your logic on how its actually read, good point
4.I actually...
THIS IS THE QUESTION:
The player must then guess a letter (ch, say). If ch is not in the word, the player is
one step closer to being hanged. If ch is in the word, the string of *s is displayed...