> 其他 >
输出Fibonacci数列1,1,2,3,5,8等的前20项,按每行5个数显示.用vb谢谢
人气:378 ℃ 时间:2020-03-23 08:16:06
解答
Private Sub Command1_Click()Dim a(1 To 20) As IntegerFor i = 1 To 20If i = 1 Or i = 2 Thena(i) = 1Elsea(i) = a(i - 1) + a(i - 2)End IfPrint a(i);n = n + 1If...刚刚的那个题的答案是多少???不是写了吗?答案是9433
推荐
猜你喜欢
© 2024 79432.Com All Rights Reserved.
电脑版|手机版