I have to write a program sort of like a hangman game. It will ask the user for a word and them prompts the user for a letter. I will tell the user how many time the letter is in the word and continue to ask for another letter.

any suggestions.

I know I need a char array

You'll also need a variable to hold the current guess, a protocol to access each element in the char array and determine if it is equal to the current guess and a variable to keep track of how many times the current char is found in the array and a loop to keep going until it's finished. Write it up, see what happens and post pertinent questions with code/error messages/etc, if you can't figure it out on your own.

Cool thanks. I will give it a try and let you know what happens.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.