title: How can I correctly sort a list of elements in Python?
body: <p>I am ordering a list of items that I replace with new ones, but by changing the letters by an equivalent in number and then ordering it, it cuts the order and does it in parts.</p>
  
  <pre><code>for (i) in range(len(unico)):
      if unico[i] == 'A':
          unico[i] = '14'
      elif unico[i] == 'D':
          unico[i] = '10'
      elif unico[i] == 'J':
          unico[i] = '11'
      elif unico[i] == 'Q':
          unico[i] = '12'
      elif unico[i] == 'K':
          unico[i] = '13'
  
  for (i) in range(len(unico2)):
      if unico2[i] == 'A':
          unico2[i] = '14'
      elif unico2[i] == 'D':
          unico2[i] = '10'
      elif unico2[i] == 'J':
          unico2[i] = '11'
      elif unico2[i] == 'Q':
          unico2[i] = '12'
      elif unico2[i] == 'K':
          unico2[i] = '13'   
  
  repetido, repetido2, unico, unico2 = 
      sorted(repetido, reverse=True), sorted(repetido2, reverse=True), 
      sorted(unico, reverse=True), sorted(unico2, reverse=True)
  
  print (unico,unico2)
  </code></pre>
  
  <p>I was expecting this output: </p>
  
  <pre><code>['14', '13', '10','8','4','3'] ['14', '13', '12', '10', '7', '6', '5']
  </code></pre>
  
  <p>..but this is what I am getting:</p>
  
  <pre><code>['8', '4', '3', '14', '13', '10'] ['7', '6', '5', '14', '13', '12', '10']
  </code></pre>