tuples, index method, Python's design

Hendrik van Rooyen mail at microcorp.co.za
Sat Apr 14 10:19:37 CEST 2007


"Martin v. Löwis" <martin at v.loewis.de> wrote:


>
> So to increase consistency, the .index method should be removed
> from lists, as well, IMO. If you find yourself doing a linear
> search, something is wrong.
>
I agree.
You should at the very least make it a binary search.
To do that you have to sort the list.
Much more efficient.

; - )

Please Sir, can I have the DoubleDict I asked for elsewhere in this thread?

- Hendrik




More information about the Python-list mailing list