Stephen Evans step...@recombinant.co.uk added the comment:
As suggested by Mark following my post on comp.lang.python I am adding further
comments to the discussion on this (closed) issue.
For a more mathematical consideration of the issue:
Stepanov, Alexander and Paul McJones. 2009. Elements
Raymond Hettinger rhettin...@users.sourceforge.net added the comment:
As discussed with Mark, am closing this one after having applied documentation
changes.
--
resolution: - rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
Mark Dickinson dicki...@gmail.com added the comment:
Of course, there are subtle implications of how it will be implemented
Indeed. Ideally, as you mention, the implementation would only use __lt__ (as
with sort and bisect). I think that constraint only leaves one reasonable
choice:
Matthew Woodcraft matt...@woodcraft.me.uk added the comment:
(1) Shouldn't 'reverse=True' be omitted in the second doc
addition?
Yes, of course, sorry.
(2) I'd also suggest adding a brief comment about what this
means for distinct, but equal, objects; otherwise it's not
really obvious
Antoine Pitrou pit...@free.fr added the comment:
As an aside, I still like Jeffrey Yasskin's suggestion on the
python-dev mailing list that the sensible definition for max would
maintain the invariant that max(iterable) be equivalent to
sorted(iterable)[-1]
What's interesting is the
New submission from Matthew Woodcraft matt...@woodcraft.me.uk:
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.
I propose making
Mark Dickinson dicki...@gmail.com added the comment:
Thanks for the patch!
Comments:
(1) Shouldn't 'reverse=True' be omitted in the second doc addition?
(2) I'd also suggest adding a brief comment about what this means for distinct,
but equal, objects; otherwise it's not really obvious what
Changes by Raymond Hettinger rhettin...@users.sourceforge.net:
--
assignee: d...@python - rhettinger
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue9802
___