title: Use of if/else in an dictionary comprehension in Python 3.x
body: <p>Suppose that i have:</p>
  
  <pre><code>l = [
      ['Brasil', 'Italia', [10, 9]],
      ['Brasil', 'Espanha', [5, 7]], 
      ['Italia', 'Espanha', [7,8]],
      ]
  </code></pre>
  
  <p>and an empty dict:</p>
  
  <pre><code>d = {}
  </code></pre>
  
  <p>I'm trying to do this operation in an dict comprehension:</p>
  
  <pre><code>for x in l:
      if (x[0] not in d):
          d[x[0]] = 0
      else:
          d[x[0]] += 1
  
  # Out: {'Brasil': 1, 'Italia': 0}
  </code></pre>
  
  <p>But when i try:</p>
  
  <pre><code>d = {k: (0 if (k not in d) else (d[k]+1)) for k in [x[0] for x in l]}
  
  # Out: {'Brasil': 0, 'Italia': 0}
  </code></pre>
  
  <p>What an i doing wrong?</p>