Size of tuples

Markus Schaber markus at schabi.de
Tue Sep 11 16:53:05 EDT 2001


Hi,

Peter van der Kamp <vdkamp at inter.nl.net> schrub:

> Thanks to the answers I understand that big tuples
> aren't really a problem. I realise that it would have
> been easy to test it myself, but sharing experiences
> isn't that bad. To answer some of the
> questions asked to me: the memory of my machine
> is 64 Mb. The reason I need a big tuple is: I'm trying
> to develop a text retrieval program in Python. Tuples
> seem to be convenient to store the references to the
> individual words of a text.

I would rather use lists instead of tuples. They have the possibility 
to be modified in-place - one can exchange words etc, and adding 
doesn't involve creating a new object.

markus
-- 
"The strength of the Constitution lies entirely in the determination of 
each citizen to defend it. Only if every single citizen feels duty 
bound to do his share in this defense are the constitutional rights 
secure." -- Albert Einstein



More information about the Python-list mailing list