recursive_lambda = lambda func: lambda *args: func(func, *args)
print(recursive_lambda(lambda self, x: x * self(self, x - 1) if x > 0 else 1)(6
    ))
print(recursive_lambda(lambda a, b: b * a(a, b - 1) if b > 0 else 1)(6))
Python lambda function to calculate factorial of a number