Please help me to use python write this question thanks Crea
Please help me to use python write this question, thanks.
Create a method that takes a string as input and then uses iteration to reverse the string.Solution
My solution:
s = raw_input(\"Enter string \")
def reverse(text):
st = \"\"
rev = \"\"
count = len(text)
print \"Lenght of text: \", len(text)
for c in range(len(text)):
count = count - 1
st = st + \"\".join(text[c])
rev = rev + \"\".join(text[count])
print \"count: \", count
print \"print c: \", c
print \"text[c]: \", text[c]
print \"Original: \", st
print \"Reversed: \", rev
return rev

