summaryrefslogtreecommitdiff
path: root/algorithms/string_reverse.py
blob: 1cebda4fc5969ffe5ca7163d91767539d899f3ee (plain)
1
2
3
4
5
6
7
#!/usr/bin/env python2


s = "Madam"
print s
print ''.join([s[i] for i in range(len(s)-1, -1, -1)])