edX_MITx_6.00.1x/Problem_Set_1/count_vowels.py

def count_vowels(s):
    count = 0
    for char in s:
        if char in 'aeiou':
            count += 1
    print("Number of vowels: {}".format(count))

count_vowels(s)

Leave a Reply

Your email address will not be published. Required fields are marked *