"CSUIDL PROGRAMMEr" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > folks > I have two lists > > i am trying to loop thorough them simultenously. > > Here is the code i am using > > f1 = os.popen('ls chatlog*.out') > data1=f1.readlines() > f1.close() > > data1=[x.strip() for x in data1] > f1 = os.popen('ls chatlog*.txt') > data=f1.readlines() > f1.close() > for eachline in data1 and line in data:
Change: for eachline in data1 and line in data: to: for eachline, line in zip(data1,data): -- Paul -- http://mail.python.org/mailman/listinfo/python-list