Size of tuples

Roy Smith roy at panix.com
Wed Sep 5 15:27:51 EDT 2001


Peter van der Kamp <vdkamp at inter.nl.net> wrote:
> I like to know if [tuples] can contain e.g. >100000 integers.

Seems to work fine:

>>> t = tuple (range (123456))
>>> len (t)
123456
>>> t[:20]
(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19)

But, why would you want to do this? :-)



More information about the Python-list mailing list