4.15.frm
来自「VB6.0应用例题」· FRM 代码 · 共 45 行
FRM
45 行
VERSION 5.00
Begin VB.Form Form1
Caption = "对角线为1其余均为5"
ClientHeight = 2400
ClientLeft = 60
ClientTop = 345
ClientWidth = 4260
LinkTopic = "Form1"
ScaleHeight = 2400
ScaleWidth = 4260
StartUpPosition = 3 '窗口缺省
Begin VB.CommandButton Command1
Caption = "单击此处"
Height = 495
Left = 2640
TabIndex = 0
Top = 720
Width = 1215
End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
Dim D%(9, 9), I%, J%
For I = 1 To 9
For J = 1 To 9
If I = J Or I = 10 - J Then
D(I, J) = 1
Else
D(I, J) = 5
End If
Next J
Next I
For I = 1 To 9
For J = 1 To 9
Print D(I, J);
Next J
Print
Next I
End Sub
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?