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