VB 简化代码
a = ""j = 0k = 1Label1.Visible = FalseFor i = 1 To 1000If i Mod 11 = 0 Thena = Str(i)j = j + 1ss: If j = 11 - k Thena = a & Chr(13)j = 0k = k + 1End IfIf k > 10 Thenk = k - 10GoTo ssEnd IfPrint a;End IfNext
参考答案:k = 10
j = 0
For i = 11 To 1000 Step 11
j = j + 1
Print i;
If j = k Then
k = k - 1
j = 0
If k = 0 Then k = 10
End If
Next