Recursion In Functional Programming In Python