11智能在线
新记
用 for 循环语句实现编写一个求n 阶乘的函数文件
找到一个 n!> 10100 的值(利用上题的n阶乘函数文件) 非常感谢你的回答,这两个问题实在是没有想出来,谢谢你们的帮忙
举报该文章
其他看法
第1个回答 2013-04-14
Private Sub Form_click()
Dim n As Integer, t As Variant
n = 1
t = 1
For n = 1 To 100
t = t * n
If t > 10100 Then Exit For
Next n
Print n
End Sub
第2个回答 2013-04-14
long chenji(int n)long tem;for(int i=1;i<=n;i++) { tem*=i; if(tem>10100) cout<<tem<<endl; } return tem;}
第3个回答 2017-08-24
你要的是求n值还是 n阶乘函数 。。。
<上一页
1
2
相似回答
大家正在搜
相关问题
急求:编写一个matlab文件,求1到n的阶乘之和。要求:输...
c语言 用 for循环语句 编写n的阶乘
编写一个js函数用来求n的阶乘
c语言 编程实现求n!要求用定义求阶乘的函数
编写函数利用for循环求n的阶乘,主函数调用该函数求5!+1...
用C语言编写程序从键盘输入一个正整数数n,输出n!
c++编写一个求阶乘n!的函数
1.使用js循环语句写出求某个数的阶乘的函数。然后用执行这个...