Write a Python Program to Count and print the Number of Each Vowel in the input string


Topic: Write a Python Program to Count and print the Number of Each Vowel in the input string

Solution

vowels = 'aeiou'
ip_str = 'India is my country'
ip_str = ip_str.casefold()
count = {}.fromkeys(vowels,0)
for char in ip_str:
   if char in count:
       count[char] += 1
print(count)



List all Python Programs