> But watch out if the lists aren't all the same length: zip won't pad out > any sequences, so it maynotbe exactly what is wanted here: > > >>> x = ['1', '2', '3'] > >>> y = ['4', '5'] > >>> for row in zip(x,y): > > print ', '.join(row) > > 1, 4 > 2, 5 >
Unfortunately the lists will be of different sizes By the way I apologise for different questions within the same thread. When I have another question, I will make a new topic -- http://mail.python.org/mailman/listinfo/python-list