title: lambda python function in reversing list
body: <pre><code>scores = []
  with open("scores.txt") as f:
      for line in f:
          name, score = line.split(',')
          score = int(score)
          scores.append((name, score))
          scores.sort(key=lambda s: s[1])
  for name, score in scores:
      print(name + ", " + str(score))
  </code></pre>
  
  <p>This code can be used to show a txt file looking like this (disordered):</p>
  
  <pre><code>alpha, 3
  beta, 1
  gamma, 2
  </code></pre>
  
  <p>To looking like this:</p>
  
  <pre><code>beta, 1
  gamma, 2
  alpha, 3
  </code></pre>
  
  <p>How can I modify the code so that it instead prints as:</p>
  
  <pre><code>alpha, 3
  gamma, 2
  beta, 1 
  </code></pre>