#12 · Strings · Beginner · 45 XP · about 5 min
Write a function called count_vowels(s) that counts the number of vowels (a, e, i, o, u) in a string.
The function should be case-insensitive (both 'A' and 'a' count as vowels).
count_vowels("hello") # Returns 2 count_vowels("AEIOU") # Returns 5 count_vowels("rhythm") # Returns 0 count_vowels("Beautiful") # Returns 5
First solves only, ranked by stars and then time.