Advertisement
Fareehausman00

Untitled

Sep 21st, 2019
135
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.22 KB | None | 0 0
  1. #vowels in a word
  2. def countVowels(word_or_phrase):
  3. vowels = 'aeiou'
  4. vowelCount = 0
  5. for w in word_or_phrase:
  6. if w in vowels:
  7. vowelCount+=1
  8. return vowelCount
  9.  
  10. print('vowels', countVowels('hippopotamus'))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement