I have no Idea how to do this and need help!
First I must create this:
1. Read a text file and store the words into an array. You can assume that the array contains at most 1000 words and each word contains at most 19chars. Thus, the array can be declared as:
const int NUMBER_OF_WORDS=1000, NUMBER-OF-CHARS=20;
char words [NUMBER_OF_WORDS][NUMBER-OF-CHARS];
2. Prompt the user to input a letter and your program count the occurrence of the letter in the entire file. Here, upper-case letter and lower-case letter are different. For example, char 'A' and char 'a' are different.
3. Prompt the user to input a word and your program count the occurrence of this word in the entire file. Here, upper case and lower-case are the same. For example, "The" is the same as "the".
4. Prompt the user to convert all letters to upper-case or lower-case and store the entire array into an output file.
5. A menu must be designed for operations 2-3. Further, the menu prompts the user to continue or terminate the operations.
Two test files, labs7-small-file.txt and labs7-large-file.txt, are provided for testing your program.
And the second part is this:
Our simple palindrome checker can identify simple cases like:
Rats live on no evil star
A smart palindrome check can even take punctuations into consideration, e.g.,
Madam, I'm Adam
The punctuations considered in this lab contains: , ; : . ? ! ' " and space.
Thus, you have to add a function to remove punctuations before processing. The function header can be:
string removePunct (const string & s, const string & punct)
where punct is a string containing all punctuations considered in this lab, and can be created by statement:
string punct (",;:.?!'\" ");
The following examples are used for you to test your program:
Able was I 'ere I saw Elba.
I Love Me, Vol. I.
Madam, I am Adam.
A man, a plan, A Canal, Panama.
Rats live on no evil STAR.
"I have no idea how to do this" usually means you are not paying attention in class, not doing the reading you need to do, are just trying to sucker someone into doing it for you, or have suckered people into doing things for you in the past and now just have no clue what is going on. Which might it be in your case?
Neither but I'm having trouble starting it because I'm not very good at this and trying to switch majors; however, I do need to get a good grade in this class regardless. Thanks so much for all the help on that post!
In cire's defence, it's not the first time you've posted something like this; an assignment brief with no signs of effort whatsoever.
Not to mention how many similar posts there are daily.
Don't forget, when people post to help on here they're giving up their time and effort. In most cases, that's preferably spent on those who attempt their work and show real effort and quest for understanding over those who are looking for a quick solution.
Was there a portion on my post that said "I really wan't to know how you feel about me asking this question"? because I really don't remember posting it. If you're not going to help stop responding to this post
Was there a portion on my post that said "I really wan't to know how you feel about me asking this question"?
No. However there was a portion of your post that said "Neither but I'm having trouble starting it" which is what I responded to. I even quoted it so the feeble of mind might realize what it was, exactly, that I was responding to.
If you're not going to help stop responding to this post
If you're intent on alienating those who might help, I would suggest continuing in this vein.
The astute may note that this is a public forum. If you don't want the public responding to what you post... don't post.
Yes but I want help with that problem not people telling me that im not paying attention in class or not reading.
Then make your posts intelligent enough that you don't give that impression. So far all you've done is say "This is my assignment. It has some pretty clear instructions, but I have no idea how to do it or even start doing it. How do I do it?"
If you want help with the problem, start solving it and ask for help when you run into issues. Otherwise, Start with 1. Move on to 2. Work your way up to 3... Getting started is as simple as tapping keys.
You'll find people are much more willing to help when you've put some effort into trying to solve the problem.