> > for n,v in enumerate(self.list): > > self.list[n]=v+'\n' > > > Is this for loop a safe technique, where the list you're enumerating over > in the for statement is the same as the one being updated in the loop > body? I always avoid things like that.
Its not changing the list, its changing the list contents. If it were adding or re,moving items from the list that would be dodgy, but modifying a existing element doesn't really change the list itself in any significant way. Alan G. _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor