How to reverse a string?
s = ‘abc’ s = s[::-1] print s
Simple!
This entry was posted on Monday, November 16th, 2009 at 11:23 am and is filed under Python. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.
You must be logged in to post a comment.