title: Get highest zorder object from matplotlib figure
body: <p>Given a matplotlib figure or plot, how can I retrieve the value of the highest zorder object? For instance, retrieving the value of <code>5</code> in this example:</p>
  
  <pre><code>import matplotlib.pyplot as plt
  import numpy as np
  fig, ax = plt.subplots(1)
  ax.plot(np.arange(10), np.arange(10), zorder=5, linewidth=5)
  ax.plot(np.arange(10), np.arange(10)[::-1], zorder=1, linewidth=5)
  # implement: get_maximum_zorder(ax) 
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/IUY2g.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/IUY2g.png" alt="enter image description here"></a></p>