title: Trying to come up with python anagram function
body: <p>What I'm trying to do is if I have a list like:</p>
  
  <pre><code>["lime", "mile", "liem", "tag", "gat", "goat", "math"]
  </code></pre>
  
  <p>I want to write a function that returns the words in the list that have an anagram, which would look like:</p>
  
  <pre><code>["lime", "mile", "liem", "tag", "gat",]
  </code></pre>
  
  <p>So far I have this code:</p>
  
  <pre><code>def anagramprinter(x):
  
      output = []     
      for i in x:
          for n in i:
              if n in x[i]:
  </code></pre>
  
  <p>I can't past this part and would like some help and would also appreciate a thorough explanation as well.</p>
  
  <p>Can anyone please show me a way that doesn't involve importing?
  Thanks</p>
  
  <p>Thanks.</p>