VB 编写用星号打印的等腰三角形

2024-11-21 19:05:07
推荐回答(1个)
回答1:

Private Sub Command1_Click()
n = 5
For i = 1 To n
Print Space(n - i);
For j = 1 To 2 * i - 1
Print "*";
Next j
Print
Next i
End Sub