In this program, we will take a string as input and count the vowels in a string.
Steps to solve the program
- Take a string as input.
- Create a list containing all the vowels and create a count variable and assign its value equal to 0.
- Use for loop to iterate over each character from the string.
- If that character is present in the vowels add 1 to the count variable.
- Print the output.
Output :