title: How to find the number of vowels in a string?
body: <p>We want to know the index of the vowels in a given word, for example, there are two vowels in the word super (the second and fourth letters).</p>
  
  <p>So given a string "super", we should return a list of [2, 4].</p>
  
  <p>My Code:</p>
  
  <pre><code>def vowel_indices(word):
      global vowels
      global vowelsList
      vowels = ["a" , "e" , "i" , "o" , "u" , "A" , "E" , "I" , "O" , "U"]
      vowelsList = []
      for letter in word:
          if letter in vowels:
              vowelsList.append(letter)
              print(len(vowelsList))
  
  vowel_indices("Anthony")
  </code></pre>
  
  <p>Instead of getting: 2, I'm getting: 1 2</p>