Nick Maclaren wrote: > It does explain why you think of lists as homogeneous, but the > analogy doesn't hold water on closer inspection. There doesn't seem > to be ANYTHING in the specification or implementation that assumes > lists are homogeneous.
Then what do you think is suggested by the fact that lists have an index() method but tuples don't? That's how this whole discussion got started -- someone wanted an explanation of why that is so. The explanation is that tuples and lists were designed for different use cases. You don't *have* to use them that way, but if you use them differently, you're on your own and can't complain if they don't have all the features you want. -- Greg -- http://mail.python.org/mailman/listinfo/python-list