title: How does iter and key in Python Max/Min Function work?
body: <p>I am relatively new to Python and i have been going over the documentation for various built-in functions. </p>
  
  <p>When it comes to max/min functions:</p>
  
  <pre><code> `max(arg1, arg2, *args[, key])`  or `max(iterable[, key])`
  </code></pre>
  
  <p>I know that arg1, arg2 etc or iterable could be a sequence of random values, however what is the role of the "key" element? Can someone give me an example of its application?</p>
  
  <p>Normally when i see this built-in function, i automatically imagine a random list say x = [1,2,3] and going max(x) would yield the value of 3. However, what could the "key" feature offer me to manipulate this function some other way than just going through a simple straightforward list?</p>
  
  <p>I am new to Python and not really up to speed with all the jargon in Python Docs.</p>
  
  <p>Thanks,
  Ed</p>