i have to match and print the words which have 3 or more consecutive vowels i wrote the regex like this:- r"[aeiou]{3,}" but this prints only the sequence of vowels from the word not the whole word
for example if i have a sentence "life is beautiful" i want to print the whole word beautiful not just eau
this this the code below:-
import re
def vowel(text):
pattern = r"[aeiou]{3,}"
result = re.findall(pattern, text)
return result
print(multi_vowel_words("Life is beautiful"))