Tuple question

Paul Rubin http
Sun Sep 5 17:27:45 EDT 2004


"Donn Cave" <donn at drizzle.com> writes:
> I expect it's used relatively infrequently, and for different
> reasons.  "if len(info) == 5", for example - just from that
> line from a relatively popular Python application, would you
> guess info is a list, or a tuple?

if I say:

   def f(*args):
       print len(args)

I'd certainly expect to receive args as a tuple, and would still want
to be able to find its length.



More information about the Python-list mailing list