Python's simplicity philosophy

David Eppstein eppstein at ics.uci.edu
Mon Nov 17 12:28:54 EST 2003


In article <7xk75ysycx.fsf at ruckus.brouhaha.com>,
 Paul Rubin <http://phr.cx@NOSPAM.invalid> wrote:

> > That's a statement only that list.sort shall be stable and
> > not that all .sort() methods must be stable.
> 
> It would be icky if some .sort() methods are required to be stable but
> others are not.  
> 
> Note that the most obvious way to implement sort() in C is to call the
> standard C library qsort function, which is unstable.

You're complaining that stability makes implementing a list-alike's sort 
trickier.  However it also can make using sort simpler.  Which do you 
think happens more often?

-- 
David Eppstein                      http://www.ics.uci.edu/~eppstein/
Univ. of California, Irvine, School of Information & Computer Science




More information about the Python-list mailing list