在数学中,N!N! 称之为 NN 的阶乘,其含义是 11 到 NN 之积,包括 NN。如 3!=1×2×3=63!=1\times2\times3=6。如下 Python 代码能输出 N!N! 的结果。

N = int(input("请输入正整数:"))rst = 0for i in range(1, N + 1):  rst *= iprint(rst)
填写答案