title: How do max and min function work?
body: <p>I have below dictionary:</p>
  
  <pre><code>d = {1: 'zz', 2: 'we', 'as': 'dfda', 'x': 'zyz'}
  </code></pre>
  
  <p>And <code>max</code> and <code>min</code> return following:</p>
  
  <pre><code>max(d)
  'x'
  
  min(d)
  1
  </code></pre>
  
  <p>How do <code>max</code> and <code>min</code> really work in this case?</p>