For I = 1 To n
s = s + p
p = 2 ^ I
Next I
I = 1
Do While I <= n '这里应该是小于等于N 不是小于N
s = s + p
p = 2 ^ I
I = I + 1
Loop
s * 0.2 / (500 * 6000000000# * 365)
结果为 3369.27年
For
I
=
1
To
n
s
=
s
+
p
p
=
2
^
I
Next
I
I
=
1
Do
While
I
<=
n
'这里应该是小于等于N
不是小于N
s
=
s
+
p
p
=
2
^
I
I
=
I
+
1
Loop
吃多少年的问题:
s
*
0.2
/
(500
*
6000000000#
*
365)
结果为
3369.27年