TAMPILAN PROGRAM MENGHITUNG PANGKAT
KODE PROGRAM
Option Explicit
Dim X As Integer
Dim Y As Integer
Dim HSL As Long
Dim I As Byte
Private Sub Command1_Click()
X = Val(Text1.Text)
Y = Val(Text2.Text)
HSL = 1
For I = 1 To Y
HSL = HSL * X
Text3.Text = Str(HSL)
Next
End Sub
Private Sub Command2_Click()
Text1.Text = ""
Text2.Text = ""
Text3.Text = ""
End Sub
Private Sub Command3_Click()
Unload Me
End Sub