VB點樣用for....next 計開方(20點)

2008-12-14 9:05 pm
VB點樣用for....next 計開方(20點)
sum = 1+ 開方2 + 開方3 + .........開方10

再用For.....Next 做呢?

請高手指點

回答 (1)

2008-12-14 9:45 pm
✔ 最佳答案
如果係 VB2008,

Dim sum As Double
For i As Integer = 1 To 10
sum += Math.Sqrt(i)
Next i
參考: programming experience


收錄日期: 2021-05-03 11:39:19
原文連結 [永久失效]:
https://hk.answers.yahoo.com/question/index?qid=20081214000051KK00759

檢視 Wayback Machine 備份