""" 计算阶乘 """ number = int(input('input number:')) n = number for i in range(number,1,-1): n = n * (i-1) print(n)
文章来源: Python 计算阶乘
""" 计算阶乘 """ number = int(input('input number:')) n = number for i in range(number,1,-1): n = n * (i-1) print(n)