[Python-3000] sets in P3K?
Terry Reedy
tjreedy at udel.edu
Thu Apr 27 00:54:17 CEST 2006
"Guido van Rossum" <guido at python.org> wrote in message
news:ca471dc20604261510j6c85563el25af280d2e2b0980 at mail.gmail.com...
> Curiously, min() and max() successfully use the same overloading.
> However, these don't have the same problem, because min() or max() of
> one value makes no sense,
The expressions 'min(x)' and 'max(x)', x an ordered set member, both make
perfect sense. (And indeed, min([x])==max([x])==x.) But since the result
is simply x, the act of *writing* the expression in code (as opposed to
expository text) does not make sense.
Thanks for the clarification on when this type of overloading can and can't
work.
Terry Jan Reedy
More information about the Python-3000
mailing list