7 lines
117 B
Python
7 lines
117 B
Python
|
|
def factorial(n, multi=1):
|
|
if 1 == n:
|
|
return multi
|
|
else:
|
|
return factorial(n - 1, multi * n)
|