Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

print string in reverse order uing for loop python

# reversing a sring using recursion
def reverse_recursion(s):
    if len(s) == 0:
        return s
    else:
        return reverse_recursion(s[1:]) + s[0]
Source by www.journaldev.com #
 
PREVIOUS NEXT
Tagged: #print #string #reverse #order #uing #loop #python
ADD COMMENT
Topic
Name
7+6 =