[填空题] 下面程序是用来打印九九乘法表的,请填空。Dim i As Integer, j As Integer, Strl $Strl =" "For i = 1 To 9 F

14 查阅

[填空题] 下面程序是用来打印九九乘法表的,请填空。

Dim i As Integer, j As Integer, Strl $

Strl =" "

For i = 1 To 9

For j = 1 To 9

If 【11】 Then

Strl =Strl +Str$ (j) +" x" +Str$ (i) +" =" +Str$ (Val(i*j))

Else

Strl = Strl & Chr( 13 )

【12】

End If

Next

Next

Print Strl

参考答案:

[11]j<=i [12]Exit for

本题考查了双重For循环和转换函数。Str $(x):把x的值转换为一个字符串;Chr(x):把x的值转换为相应的ASCII字符。

计算机考试