title: Python List Comprehesion conversion
body: <p>So I have a script like this</p>
  
  <pre><code>for key, Value in mydictionary.iteritems():
      if 'Mammal' in Value[1]: 
      #because the value is a list of 2 items and I want to get at the second one
          Value[1] = Value[1].strip('Mammal')
  </code></pre>
  
  <p>This code effectively removes Mammal from the beginning of the second item in the Value list. Now I want to make this nicer python looking with list comprehension so I came up with this but obviously is wrong.... Any help?</p>
  
  <pre><code>Value[1] = [Value[1].strip('Mammal') for Key, Value in mydictionary.iteritems() if 'Mammal' in Value[1] ]
  </code></pre>
  
  <p>Also, on the same lines, a list comprehension to list all the keys in this dictionary. I am having a hard time coming up with that one. </p>
  
  <p>I came up with:</p>
  
  <pre><code>for key, Value in mydictionary.iteritems():
  Templist.append(key)
  </code></pre>
  
  <p>but as a list comprehension I am thinking....but it doesn't work :(</p>
  
  <pre><code>alist = [key for Key, Value in mydictionary.iteritems()]
  </code></pre>