boblat...@googlemail.com wrote: > this is the conversion I'm looking for: > > ['1.1', '2.2', '3.3'] -> (1.1, 2.2, 3.3) > > Currently I'm "disassembling" the list by hand, like this: > > fields = line.split('; ') > for x in range(len(fields)): > fields[x] = float(fields[x]) > ftuple = tuple(fields) > > Of course it works, but it looks inelegant.
temp = map(float, x) ftuple = tuple(temp) Of course this is also possible to write in a single line. Uli -- Sator Laser GmbH Geschäftsführer: Thorsten Föcking, Amtsgericht Hamburg HR B62 932 -- http://mail.python.org/mailman/listinfo/python-list