On Fri, Jun 8, 2012 at 5:10 PM, Mike Nickey <mnic...@gmail.com> wrote:
> def compareElements(wordList): > for item in wordList(): > if item == item.reversed(): > print item > else: > next(item) > > reversed() is not a string method. To reverse a string, try something like this: > if item == item[::-1] > http://stackoverflow.com/questions/931092/reverse-a-string-in-python
_______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor