converting tuple to a list
Mikael Olofsson
mikael at isy.liu.se
Wed Jan 12 07:58:28 EST 2000
More information about the Python-list mailing list
Wed Jan 12 07:58:28 EST 2000
- Previous message (by thread): converting tuple to a list
- Next message (by thread): PhotoImage.zoom problem
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On 12-Jan-00 Anders M Eriksson wrote: > Is this the 'best' way to convert a tuple to a list? > > t = (1,2,3,4,5) > l = [] > > for i in range(len(t)): > l.append(t[i]) I don't know if this is better, but at least it looks better to me. l=map(None,t) /Mikael ----------------------------------------------------------------------- E-Mail: Mikael Olofsson <mikael at isy.liu.se> WWW: http://www.dtr.isy.liu.se/dtr/staff/mikael Phone: +46 - (0)13 - 28 1343 Telefax: +46 - (0)13 - 28 1339 Date: 12-Jan-00 Time: 13:57:01 This message was sent by XF-Mail. -----------------------------------------------------------------------
- Previous message (by thread): converting tuple to a list
- Next message (by thread): PhotoImage.zoom problem
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list