在Command1中写入如下代码:
Dim n As Integer
TextBox2.Text = ""
For i = 0 To TextBox1.Lines.Count - 1
If TextBox1.Lines(i) <> "" Then
n = TextBox1.Lines(i)
If n Mod 2 = 0 Then
TextBox2.Text = TextBox2.Text & "偶" & vbCrLf
Else
TextBox2.Text = TextBox2.Text & "奇" & vbCrLf
End If
End If
Next
不知道这与二维数组有什么关系?与5个一组又有什么关系?
追问只是感觉后续的功能用2维数组会比较方便。
追答哦