Anti Vowel


#1

Although I saw the correct code which is the correct answer for this exercise, I still want to know why my code was not working.

3

return new

Thank you.


#2

difficult thing to explain the best thing is to show you:

new=text.replace(letter,"")
print new

add the print statement to print new, and a function call so we can actually see the print statement in action:

print anti_vowel("that the this donut")

i on purpose picked a string with all the different vowels, so you can see that only the last replace action persist because text doesn’t change


#3

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.