Answered You can hire a professional tutor to get the answer.

QUESTION

def allVowelsA(word): Note: empty string is legal, and should return empty string (a) make sure word is of the correct type if (type(word)!=str):

def allVowelsA(word):

Note: empty string is legal, and should return empty string

(a) make sure word is of the correct type

if (type(word)!=str):

________________________________________

(b) if word is empty string, return empty string

__________________________________________:

return ""

# Now we know we have at least one letter in the word vowels="aeiouyAEIOUY"

# (c) If the first letter in the word is a vowel...

if ( _________________________ in vowels):

ch = 'a'

else:

# (d) Otherwise, keep the same letter

ch = _________________________

# (e) Combine the first letter with a recursive call on rest of word return ch+_______________________________________________

allVowelsA("by") produces "ba"

allVowelsA("alien") produces "alaan"

allVowelsA("boot") produces "baat"

allVowelsA("fruition") produces "fraataan"

Show more
LEARN MORE EFFECTIVELY AND GET BETTER GRADES!
Ask a Question