Hi, I wrote a simple program for class and its made to run with input using linux redirection, the problem is that it just stops about after about the 20th line, pretty much after my variable declarations and first cout statement. I tested it and it never even gets to my first loop, just looking for any help or ideas. It does do the first cout command and shows me the first string in my file and then nothing after that, doesnt even do cout << count2.
I was trying to create a loop that would check to see if the first character of the string was alphanumeric, and if it was, to remove it from the string, then check what would be the new first character and do the same. As for line 53, I would just have to change that value to (last - 1)?
The goal of the assignment was to take words from a file, count consonants, vowels, words and characters, remove any non-alphanumeric characters from the beginning and end of the word, and then take any words with odd number of letters, and change the case of the letter in the middle of the word. Then at the end display the words in lines of 10 words per line, and then display the total vowels, consonants, characters, words and average word length before and after any changes.