hi guys...
I have to write a programme that plays a game of hangman with following feeatures:
1.the programme start by reading from an input file a list of words and stores them in an array of string.
2.the programme then selects randomly one of the words. the word should appears like *****
3.the programme should includes 3 functions:
a. function to read the list of words.
b. function to find the number of occurrences and locations of a guessed letter
c.test if a game has terminated (6 incorrect guesses attempted).
sample output:
hangman
the word: **
guess a letter: f
not exists
**
guess a letter: h
h exists 1 time in the word
h*
guess a letter: i
i exists 1 time in the word
hi
bravo
play again? (Y/N): N
thank you