title: Get the first element of each tuple in a list in Python
body: <p>An SQL query gives me a list of tuples, like this:</p>
  
  <pre><code>[(elt1, elt2), (elt1, elt2), (elt1, elt2), (elt1, elt2), (elt1, elt2), ...]
  </code></pre>
  
  <p>I'd like to have all the first elements of each tuple. Right now I use this:</p>
  
  <pre><code>rows = cur.fetchall()
  res_list = []
  for row in rows:
      res_list += [row[0]]
  </code></pre>
  
  <p>But I think there might be a better syntax to do it. Do you know a better way?</p>