In CPython, the builtin max() and min() have the property that if there
are items with equal keys, the first item is returned. From a quick look
at their source, I think this is true for Jython and IronPython too.

However, this isn't currently a documented guarantee. Could it be made
so? (As with the decision to declare sort() stable, it seems likely that
by now there's code out there relying on it anyway.)

-M-


_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to