Private Sub Command1_Click()
Dim s As String, i As Integer, d As Integer
d=0
s = Text1.Text
For i = Len(s) To 1 Step -1
d = (d \ 2 + Val(Mid(s, i, 1)) * 2 ^ (Len(s) - 1))
Next i
Text2.Text = Str(100-d)
End Sub
微信扫码预览、分享更方便