Private Sub Button1_Click(ByVal sender As System.Object, ByVal e

Anuncio
ELEVAR UN # A LA POTENCIA…
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button1.Click
Dim a, ex, i, p As Integer
a = TextBox1.Text
ex = TextBox2.Text
i = 1
p = 1
Do While (i <= ex)
p = p * a
i = i + 1
Loop
TextBox3.Text = p
End Sub
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button2.Click
TextBox1.Text = " "
TextBox2.Text = " "
TextBox3.Text = " "
End Sub
Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button3.Click
End
End Sub
End Class
Descargar