LUAS DAN KELILING LINGKARAN
Nama : SRIWAHYUNI
NIM : 19010020
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim phi As Integer
Dim Luas As Integer
Dim keliling As Integer
phi = 22 / 7
Luas = phi * (TextBox1.Text * TextBox1.Text)
keliling = 2 * phi * TextBox1.Text
TextBox2.Text = Luas
TextBox3.Text = keliling
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
End Class
Komentar
Posting Komentar