dim m(5,5),s(5) for i=1 to 5 s(i)=0 for j=1 to 5 m(i,j)=i+j s(i)=s(i)+m(i,j) next j next ifor each x in sprint x;next x这个题的最终答案是20 25 30 35 40所不理解是就是关于问题补充部分中for each x in
来源:学生作业帮助网 编辑:六六作业网 时间:2024/11/26 19:48:25
dimm(5,5),s(5)fori=1to5s(i)=0forj=1to5m(i,j)=i+js(i)=s(i)+m(i,j)nextjnextiforeachxinsprintx;nextx这个题
dim m(5,5),s(5) for i=1 to 5 s(i)=0 for j=1 to 5 m(i,j)=i+j s(i)=s(i)+m(i,j) next j next ifor each x in sprint x;next x这个题的最终答案是20 25 30 35 40所不理解是就是关于问题补充部分中for each x in
dim m(5,5),s(5) for i=1 to 5 s(i)=0 for j=1 to 5 m(i,j)=i+j s(i)=s(i)+m(i,j) next j next i
for each x in s
print x;
next x
这个题的最终答案是20 25 30 35 40
所不理解是就是关于问题补充部分中for each x in
dim m(5,5),s(5) for i=1 to 5 s(i)=0 for j=1 to 5 m(i,j)=i+j s(i)=s(i)+m(i,j) next j next ifor each x in sprint x;next x这个题的最终答案是20 25 30 35 40所不理解是就是关于问题补充部分中for each x in
s是一个数组
for each x in s
print x
next
和
for i=1 to ubound(s)
x=s(i)
print x
next i
结果是一样的
for each x in s,从s的第一个元素开始,x就表示s的一个元素s(i),直到最后一个元素
dim I% ,S% s=0 for I=5 to 1 s=s+i next I print “s=” ; s 怎么看的 dim I% ,S%s=0for I=1 to 5 step -1s=s+inext Iprint “s=”;s 还有这个一起求解释~
VB中 Option ExplicitPrivate Sub Form_Click()Dim 5Fg Integer (1)Dim L * og As Long (2)Dim s - ig As Single (3)Dim dob_ As Double (4)Dim _Name AS String (5)Dim bln@ Frag As Boolean (6)Dim do As Data (7)End Sub电脑上的提示
Private Sub Command0_Click() Dim a(10, 10) For m = 2 To 4 For n = 4 To 5 a(m, n) = m * n Next n Nex答案是42.谁能帮我解析一下啊?谢谢!Private Sub Command0_Click() Dim a(10, 10) For m = 2 To 4 For n = 4 To 5 a(m, n) = m * n Next n
怎么理解vb中 dim m(10) for i=1 to 5 m(i)=i*i next i print m(i-1)
dim m(5,5),s(5) for i=1 to 5 s(i)=0 for j=1 to 5 m(i,j)=i+j s(i)=s(i)+m(i,j) next j next ifor each x in sprint x;next x这个题的最终答案是20 25 30 35 40所不理解是就是关于问题补充部分中for each x in
Dim m%,n% For m=1 To 3 For n=1 To 5 Step 2 n=n+1 Next n Next m.问n=n+1执行多少次
dim i as integer dim sum as integer sum=0 for i=0 to 5 sum=sum+i next sum=?
..Dim a() a=Array(1,3,5,7,9) s=0 For i=1 To 4 s=s*10+a(i) Next i Print s 为啥答案是3579
Private Sub command1_click() Dim m(10) For k = 1 To 10 m(k) = 11 - k Next k x = 5 Print m(2 + m(x))VB的一个程序
看程序,)private sub form-click()dim a(5,5) as integer,s(5) as integerfor i=1 to 5s(i)= 0for j=1 to 5m(i,j)=i+jnext jnext ifor each x in sprint x;nextend sub
请帮忙解释下面语句意思-2'填写遗漏值 Dim n As Integer Dim arrR() As Integer, arrB() As Integer ReDim arrR(5), arrB(5) Dim r As Range Dim k As Long Dim t As Integer arrR(0)
编程计算1*2+3*4+5*6+7*8+9*10Private Sub command1_click()Dim s As Integer, i As Integers = 0For p = 1 To 10 Step 2For j = 2 To 10 Step 2 s = s + kNext jNext p Print s End Sub 怎么更改才对 要快
VB程序如下:Dim a a = Array(1,2,3,4,5,6,7,8) i = 0 For k = 100 To 90 Step -2完全看不懂...要详解..VB程序如下:Dim aa = Array(1,2,3,4,5,6,7,8)i = 0 For k = 100 To 90 Step -2s = a(i)^2If a(i) > 3 Then Exit Fori = i + 1Next kPrint k; a(
a = array(1,2,3,4,5):for k = 1 to 4:s = s + a(k)中的s = s + a(k)这条语句是什么意思?窗体上有一个命令按钮,命令按钮的单击事件如下:Private Sub command1_click()dim aa = array(1,2,3,4,5)for k = 1 to 4 s = s + a(k)nextprint
VB编程option base 1private sub command1_click() dim d d=array(1,2,3,4,5) n=1 for k=5to 3step-1 s=s+d(k)*n n=n*10 next k print s end sub 为啥结果是345
VB计算 1-1/3!+1/5!-1/7!+……+(-1)^(n-1)/(2n-1)!请填空Private Sub Command1_Click()Dim i As Integer,j As IntegerDim n As IntegerDim s As Doublej=1s=1n = Val(Text1.Text)For i = 2 To nj=__________ '计算1/(2*i-1)!s=_______________' l累加
编写程序计算1+3+5+……+99的值,这是个填空题.private sub command1_click()dim i,s as integers=0for i=1 to ____________s=s+(2*i-1)_______________print s=;send sub答案是第一空填50,为什么最大是99,要填50呢?这个50是怎么
VB练习题7道,七道全讲完才行一、Private Sub Command1_Cilck()Dim a(4,4)For i = 1 To 4For j = 1 To 4Next jNext iFor j = 3 To 4For j = 3 To 4Print a(j,i);Next jEnd Sub9 1210 13二、Private Sub Form _Click()Dim a(10),p(3)As Integerk = 5For i