Sorting out sort

Anders J. Munch andersjm at inbound.dk
Sat Jan 4 14:02:09 CET 2003


"Mel Wilson" <mwilson at the-wire.com> wrote:
>
> Still, we give up the right to write
>
> i = s[:].sort().index(a)

This is equivalent to (using my sort function):
    i  = sort(s).index(a)

functional-sort-comes-to-the-rescue-again-ly y'rs, Anders







More information about the Python-list mailing list