Anti Vowels throwing a syntax error


#1

Hello everybody,

I’m trying to run this code:

def anti_vowel(text):
	anti = ""
 	vowels: "aieouAIEOU"
  for i in text:
    for v in vowels:
      if v == i:
        i = ""
      else:
        i = i
  	anti += i
  return anti
      

and what I get is:

File “python”, line 3
vowels: “aieouAIEOU”
^
SyntaxError: invalid syntax

I have no idea why. Would appreciate any help on this.
Thank you in advance!


#2

are you attempt to name/declare a variable here:

vowels: "aieouAIEOU"

this requires an equal sign, look at the line above where you declared anti variable


#3

oh wow didnt even notice i put a colon there. thanks!


#4