the point of my recursion function is to print integers in reverse order. def rDisp(s): n=str(s) if n == "": return n else: return rDisp(n[1:]) + n[0]
def main():
number=(int(input("Enter a number :")))
rDisp(num)
main()
If within the main function I implement print(reverseDisplay(number)), it works, however, for the purpose of this code, I want the reverseDisplay function to do the printing. How would I go about implementing the print function into that block of code.
Thanks!