My program is supposed to reverse the string inputted, print it then extract the numbers and print the numbers of the reversed string in a list.

Code:
def reverse_str(string):
    revstring =('')
    length=len(string)
    i = length - 1
    while i>=0:
        revstring = revstring + string[i]
        i = i - 1
    return revstring
def strip_digits(string):
    result = []
...