How can I have one element list or tuple?

nico nicolas.berney at gmail.com
Thu Nov 1 12:21:40 EDT 2007


The following example returns a string type, but I need a tuple...
>>> var = ("Hello")
>>> print type(var)
<type 'str'>

I need that for a method parameter.
Thx




More information about the Python-list mailing list