title: SyntaxError: invalid syntax while building a dict from a list using Python 2.6
body: <p>I created a Python script with Python2.7 and it works fine. However, when I run the same script with Python2.6, I got a "SyntaxError: invalid syntax" error.</p>
  
  <p>After investigating, the problem seems to be related to a for loop. </p>
  
  <pre><code>l1 = [["a1", "a2"], ["b1", "b2"]]
  print {item[0]:item[1] for item in l1}
  </code></pre>
  
  <p>When I run the above code with Python 2.7, I've got the following output:</p>
  
  <pre><code>{'a1': 'a2', 'b1': 'b2'}
  </code></pre>
  
  <p>When I run the same code with Python 2.6, I've got the following error:</p>
  
  <pre><code>&gt;&gt;&gt; l1 = [["a1", "a2"], ["b1", "b2"]]
  &gt;&gt;&gt; print {item[0]:item[1] for item in l1}
    File "&lt;stdin&gt;", line 1
      print {item[0]:item[1] for item in l1}
                               ^
  SyntaxError: invalid syntax
  &gt;&gt;&gt;
  </code></pre>
  
  <p>Any help is appreciated.</p>
  
  <p>Regards,<br>
  Allen</p>