word = raw_input("Your word:") container = list(str(word)) rev_container =  def reverse(word): iters = len(container) n = iters -1 for i in container: rev_container.append(container[n]) container.remove(container[n]) return i reverse(word) drow = ''.join(rev_container) print drow
everything you need to reverse the string, should be inside the function
Thank you, I could correct the code!
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.