求解VB 假定有下面程序段 For i=1to3 For j=1 to i For k=j to 3 ...

2024-12-15 01:11:56
推荐回答(1个)
回答1:

开vb,画个按钮,之后在按钮上写代码:
Private Sub Command1_Click()
For i = 1 To 3
For j = 1 To i
For k = j To 3
Print "i="; i, "j="; j, "k="; k
Next k
Next j
Next i
End Sub

运行就能得到答案了。
共得到14行3列的数据。