title: Create a function that contains only the first occurrence of a letter from the original phrase
body: <p>The function needs to behave as follow: <a href="https://i.stack.imgur.com/E2QCl.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/E2QCl.png" alt="enter image description here"></a></p>
  
  <p>The first letter occurrence can be upper or lower case (newPhrase).
  Non-alpha characters - are left unchanged.</p>
  
  <p>So far I thought of :</p>
  
  <pre><code>def keepFirstLetter(phrase):
  '''Returns a new string that contains only the first occurrence of a 
  letter from the original phrase. 
  
      letterSeenSoFar = ''
      newPhrase = ''
      if (letterSeenSoFar == '' or letterSeenSoFar[-1] != letterSeenSoFar):
           letterSeenSoFar += c
      for letter in letterSeenSoFar:
          if letter.isalpha:
              newPhrase += char
          else:
              newPhrase += letter
      return newPhrase
  </code></pre>