def reverse (text):
rev_text = ""
count = -1
for i in text:
rev_text = rev_text + text[count]
count -= 1
Output is !nohtyP
i did this and get the correct answer, but confused. Can anyone explain.. rev_text = rev_text + text[count] & count -= 1 works..Thanks in advance..
Replace this line with your code.