[Tutor] For loop breaking string methods

C M Caine cmcaine at googlemail.com
Mon Apr 26 22:58:15 CEST 2010


Thank you for the clarification, bob.

For any future readers of this thread I include this link[1] to effbot's
guide on lists, which I probably should have already read.

My intention now is to modify list contents in the following fashion:

for index, value in enumerate(L):
    L[0] = some_func(value)

Is this the standard method?

[1]: http://effbot.org/zone/python-list.htm

Colin Caine
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/tutor/attachments/20100426/64ca8ffa/attachment-0001.html>


More information about the Tutor mailing list