📅  最后修改于: 2022-03-11 14:46:03.144000             🧑  作者: Mango
代码示例2
def factorial(n):
if n == 1:
return 1
else:
return n*factorial(n - 1)
print(factorial(3))
print(factorial(4))
print(factorial(5))