fork download
  1. def recursive_lambda(func):
  2. def ret(*args):
  3. return func(ret, *args)
  4. return ret
  5.  
  6. print(recursive_lambda(lambda factorial, x: x * factorial(x - 1) if x > 1 else 1)(6)) # 720
Success #stdin #stdout 0.06s 9568KB
stdin
Standard input is empty
stdout
720