I have created 2 versions of the function that return correct responses, but neither pass as correct answer:
Even when I change 'print' to 'return' (as suggested in previous posts) I receive None in the viewer window but either way I still receive this error message:
Your function fails on anti_vowel("Hey look Words!"). It returns "None" when it should return "Hy lk Wrds!".
Here's my code with examples:
1. def anti_vowel(text): for c in text: if c not in "aeiouAEIOU": print c anti_vowel("Hey look Words!") """prints: H y l k W r d s !""" 2. def anti_vowel(text): new_text = " " for c in text: if c not in "aeiouAEIOU": new_text += c print new_text anti_vowel("Hey look Words!") """Returns: Hy lk Wrds!"""
Sorry if this is a repeat question, I tried to read every single other anti_vowel post before posting.