VB输出菱形图形
答案:4 悬赏:70 手机版
解决时间 2021-01-15 19:24
- 提问者网友:萌卜娃娃
- 2021-01-15 03:55
VB输出菱形图形
最佳答案
- 五星知识达人网友:孤独的牧羊人
- 2021-01-15 05:32
Private Sub Command1_Click()
For i = -4 To 4
Print Tab(Abs(i) + 1);
For j = Abs(i) - 4 To 4 - Abs(i)
Print CStr(1 + Abs(i) + Abs(j));
Next j
Print
Next i
End Sub
For i = -4 To 4
Print Tab(Abs(i) + 1);
For j = Abs(i) - 4 To 4 - Abs(i)
Print CStr(1 + Abs(i) + Abs(j));
Next j
Next i
End Sub
全部回答
- 1楼网友:患得患失的劫
- 2021-01-15 06:42
Private Sub Command1_Click()
For j = 5 To 2 Step -1
Print Tab(3 * j);
For i = 5 To j Step -1
Print i;
Next
For k = j + 1 To 5
Print k;
Next
Print
NextFor j = 1 To 5
Print Tab(3 * j);
For i = 5 To j Step -1
Print i;
Next
For k = j + 1 To 5
Print k;
Next
Print
NextEnd Sub第二种
Private Sub Command2_Click()For j = 5 To 2 Step -1
Print Tab(5 + j);
For i = 5 To j Step -1
b = b & i
Next
For k = j + 1 To 5
b = b & k
Next
Print b
b = ""
Next
For j = 1 To 5
Print Tab(5 + j);
For i = 5 To j Step -1
b = b & i
Next
For k = j + 1 To 5
b = b & k
Next
Print b
b = ""
NextEnd Sub
For j = 5 To 2 Step -1
Print Tab(3 * j);
For i = 5 To j Step -1
Print i;
Next
For k = j + 1 To 5
Print k;
Next
NextFor j = 1 To 5
Print Tab(3 * j);
For i = 5 To j Step -1
Print i;
Next
For k = j + 1 To 5
Print k;
Next
NextEnd Sub第二种
Private Sub Command2_Click()For j = 5 To 2 Step -1
Print Tab(5 + j);
For i = 5 To j Step -1
b = b & i
Next
For k = j + 1 To 5
b = b & k
Next
Print b
b = ""
Next
For j = 1 To 5
Print Tab(5 + j);
For i = 5 To j Step -1
b = b & i
Next
For k = j + 1 To 5
b = b & k
Next
Print b
b = ""
NextEnd Sub
我要举报
如以上回答内容为低俗、色情、不良、暴力、侵权、涉及违法等信息,可以点下面链接进行举报!
点此我要举报以上问答信息
大家都在看
推荐资讯