title: Extracting specific elements of a list of lists in Python
body: <p>Here's a list:</p>
  
  <pre><code>foo=[(1, 2, {'weight': 1}), (1, 3, {'weight': 2}), (1, 4, {'weight': 3}), (`1 5, {'weight': 4}), (1, 6, {'weight': 5}), (1, 7, {'weight': 6})]
  </code></pre>
  
  <p>Say I wanted to extract a particular element of each list within foo and store it in a separate list.</p>
  
  <p>e.g. I wanted to extract 2nd element from each list, within foo and save it in the array labelled bar.</p>
  
  <pre><code>bar=[2,3,4,5,6,7]
  </code></pre>
  
  <p>How can this be done in Python 2.7x?</p>