①信息可以重复使用而不产生损耗
②信息的表示、传播、存储不一定依附于某种载体
③信息可以脱离它所反映的事物被存储、保存和传播
④信息的加工和管理必须使用计算机才能完成
⑤近代信息技术有摄影技术、微电子技术、广播和电视技术
依次对音频文件进行如下操作:
①将后 5 秒音频设为静音
②将右声道上音频删除
③直接保存处理后的音频文件
则处理后的音频文件与原文件的存储容量之比约为( )
If a>b Then t=a:a=b:b=t s=a+b
a=s-a b=s-b
已知变量a和b中的值均为正整数,且a的值大于b的值,执行该程序段后,值最终未发生改变的变量是( )
1 | 5 | 7 | 9 |
4 | 6 | 10 | 15 |
8 | 11 | 12 | 19 |
14 | 16 | 18 | 21 |
已知数据逐行存储在数组a中,在杨氏矩阵数组中查找某数字是否存在的VB程序段如下:
cz = False : i = 1 : j = n
Do While j >= 1 And i <= n
If key < a(s) Then
⑵
ElseIf key > a(s) Then
⑶
Else
cz = True:Exit Do
End If
Loop
方框中的代码由以下三部分组成:
①j = j - 1
②s = (i - 1) * n + j
③i = i + 1
代码顺序正确的选项是( )
L = 0: R = 7: i = 1
Do While i < R
If a(i) = 0 Then
L = L + 1
t = a(i): a(i) = a(L): a(L) = t i = i + 1
ElseIf a(i) = 2 Then
R = R - 1
t = a(i): a(i) = a(R): a(R) = t
Else
i = i + 1
End If
Loop
数组元素 a(1)到 a(6)的值依次为“2,0,2,1,1,0”。执行该程序段后,下列说法不正确的是( )
i = 1
Do While i<=6
a(i) = Int(Rnd * 10) + 1
If a(i) Mod 2 = i Mod 2 Then i = i + 1
Loop
For i = 1 To 2
k = 1
For j = 1 To 6 - i * 2
If a(j) * k > a(j + 2) * k Then
t = a(j): a(j) = a(j + 2): a(j + 2) = t
End If
k = -k
Next j
Next i
执行该程序段后,在下列选项中,a(1)~a(6)各元素值可能的是( )
2 图
1 图
2 图
Private Sub Command1_Click()
Dim a As Integer
Randomize
Text1.Text = Str(a)
End Sub
Private Sub Command2_Click()
Dim L As Integer, R As Integer, m As Integer
Dim x As Integer, square As Integer
x = Val(Text1.Text) L = 0
R =
Do While L < R
'改错
square = m * m
If square > x Then
R = m - 1
Else
End If
Loop
Text2.Text = Str(L)
End Sub
Private Sub Command1_Click()
Dim n As Integer, L As Integer, t As Integer
Dim i As Integer, j As Integer, k As Integer
Dim s As String, result As String
Dim a(1 To 50) As Integer, dir(1 To 50) As Integer
L = Val(Text1.Text): n = Val(Text2.Text): t = Val(Text3.Text) s = Text4.Text
s = s + ".": tmp = 0: k=0
For i = 1 To Len(s)
ch = Mid(s, i, 1)
If ch >= "0" And ch <= "9" Then
tmp = tmp * 10 + Val(ch)
Else
k = k + 1
a(k) = tmp: dir(k) = 1
tmp = 0
End If
Next i
For i = 1 To t
For j = 1 To n
IfThen dir(j) = -dir(j)
Else
For c = 1 To n
IfThen dir(c) = (-1) * dir(c)
dir(j) = (-1) * dir(j)
End If
Next c
End If
Next j
Next i
For i = 1 To n
result = result + Str(a(i))
Next i
Label5.Caption = Str(t) + "秒后小球的位置为:" + result
End Sub