题型:综合题 题类:模拟题 难易度:普通
浙江省教育绿色评价联盟2018届高三下学期信息技术选考适应性考试试卷
Private Sub Command1_Click()
Dim S As String
Dim n As Integer
Dim cnt As Integer
Dim i As Integer
Dim num As Single
Dim cd As Single
Dim ave As Single
s=Text1.Text
n=Len(s)
hum=0
cd=0
cnt=0
For i=1 To n
①
If c>“a”And c<=“z” Or c>=“A”And c<=“Z”Then
cnt=cnt+1
Elself c>=”0”And c<=”9”Then
cnt=cnt+1
Else
If cnt>0 Then
num=num+1
cd=cd+cnt
②
End If
End If
Next i
If cnt>0 Then
num=num+1
cd=cd+cnt
End If
Ave=cd/num
Label1.Caption=“总共有”+Str(num)+“个单词,平均长度为”+Str(ave)
End Sub
① ②
试题篮