On Mon, 28 Mar 2005 13:39:17 +0200, remi <[EMAIL PROTECTED]> wrote: >Hello, > >I have got a list like : mylist = ['item 1', 'item 2',....'item n'] and >I would like to store the string 'item1' in a variable called s_1, >'item2' in s_2,...,'item i' in 's_i',... The lenght of mylist is finite ;-) >Any ideas ? >Thanks a lot. >Rémi.
Why not just access the list by index? Just start with zero instead of 1. mylist = ['item 1', 'item 2',....'item n'] mylist[0] is 'item 1' mylist[1] is 'item 2' . . mylist[n-1] is 'item n' Ron Adam -- http://mail.python.org/mailman/listinfo/python-list