Question
Write a program that reads a string and outputs the number of times each vowel appears in it and the number of characters that are
Write a program that reads a string and outputs the number of times each vowel appears in it and the number of characters that are not vowels. Your program must contain a function with one of its parameters as a string variable and six other integer reference parameters : five representing the number a particular vowel appears in the string and one representing the number of non-vowel characters (including the space character). The main program function should request a string input from the user and then display the results of the function.
Function Definition : void vowelCount(string wordInput, int& aCount, int& eCount, int& iCount, int& oCount, int& uCount, int& notVowelCount) ; -- 30 points
And also use :
Function Definition : int searchChar(char,string) ; //Returns the number of times // a character appears in a string. Not case sensitive 15 points
For example: the return value for searchChar(6, 123466) is 2 since there are two 6s in 123466 and for searchChar(e,Wake Tech) return value is 2 since there are 2 es in Wake Tech; searchChar(5, 123466) is 0 since no 5s in 123466.
The following is a sample output :
Enter a string for vowel analyzing : Programming Is GREAT
Number of as : 2
Number of es : 1
Number of is : 2
Number of os : 1
Number of us : 0
Number of non-vowels : 12
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started