3:a(n,1) 7 a(n,8)
Dim i As Integer, max As Single, j As Integer For i = 1 To 5
If max < getmark(i) Then max = getmark(i) j = i End If Next i
Text2.Text = athlete(j) Text3.Text = max 26: 2(1):
If op1.Value Then Text1.Text = \我是\ If op2.Value Then Text1.Text = \我是\
If ch1.Value = 1 Then Text1.Text = \我的爱好是\ If ch2.Value = 1 Then Text1.Text = \我的爱好是\
If ch1.Value = 1 And ch2.Value = 1 Then Text1.Text = \我的爱好是\& _ ch1.Caption & ch2.Caption 2(2):0 1000 list1.list(i) 3:
'通用声明
Dim n1 As Integer, n2 As Integer, n3 As Integer Dim n4 As Integer, n5 As Integer, n6 As Integer
'读数
Private Sub Command1_Click() Dim m As String
Open app.path & \ m = Input(LOF(1), 1) Close 1
Text1.Text = m End Sub
'统计
Private Sub Command2_Click()
Dim i As Integer, s As String, c As String s = Text1.Text For i = 1 To Len(s)
c = UCase(Mid(s, i, 1)) If c = \ n1 = n1 + 1 ElseIf c = \
n2 = n2 + 1
ElseIf c = \ n3 = n3 + 1
ElseIf c = \ n4 = n4 + 1
ElseIf c = \ n5 = n5 + 1
ElseIf c = \ n6 = n6 + 1 End If Next i End Sub
'存盘
Private Sub Command3_Click()
Open App.Path & \ Print #1, n1; n2; n3; n4; n5; n6 Close 1 End Sub 27: 2(1):
Private Sub Command1_Click() If Option1.Value Then
Text1.Text = List1.Text & Option1.Caption Else
Text1.Text = List1.Text & Option2.Caption End If End Sub 2(2):0 isum+j 1250 3:
'通用声明
Private Type studinfo name As String * 8 sex As String * 4 age As Integer End Type
'显示
Private Sub Command1_Click() Dim std As studinfo, i As Integer
Open App.Path & \ For i = 1 To 5 Get #1, i, std
Text1.Text = Text1.Text & std.name & std.sex & std.age & vbCrLf Next i Close 1 End Sub
'保存
Private Sub Command2_Click()
Open App.Path & \ Print #1, Text1.Text Close 1 End Sub 28 2(1):
Dim i As Integer, max As Integer, min As Integer Dim j As Integer, b(100) As Integer For i = 1 To 100
If isnarc(a(i)) Then j = j + 1 b(j) = a(i) End If Next i
max = b(1): min = b(1) For i = 2 To j
If max < b(i) Then max = b(i) If min > b(i) Then min = b(i) Next i
Text1.Text = max Text2.Text = min 2(2):
Private Sub c1_Click()
Dim i As Integer, s As Long, n As Integer n = cb1.Text For i = 1 To 5000
If i Mod n = 0 Then s = s + i Next i
Text1.Text = s End Sub 3:
a(k) ch
Dim i As Integer, j As Integer, t As Integer For i = 1 To 49
For j = i + 1 To 50 If a(i) > a(j) Then
t = a(i) a(i) = a(j) a(j) = t End If Next j Next i
For i = 1 To 50
Text2.Text = Text2.Text & Str(a(i)) Next I 29:
2(1):index true form1.width 2(2):Lbound Ubound a < 3:
Dim s As Integer '通用声明 Private Sub read_Click() ReadData End Sub
Private Sub calc_Click() Dim i As Integer For i = 1 To 100
If i Mod 2 = 0 Then s = s + Arr(i)
Text1.Text = Text1.Text & Str(Arr(i)) End If Next i Print s End Sub
Private Sub save_Click() WriteData \End Sub 30: 2(1):form1 form1.visible 2(2):
Private Sub op1_Click() Dim m As String m = Text1.Text
Text1.Text = Text2.Text Text2.Text = m
Text3.Text = \交换成功\ op1.Visible = False
0
a(i) arr2

