Sabtu, 31 Oktober 2009

programmer_muda

Contoh VB


Sub identitas()
a = InputBox("masukan nama anda?")
MsgBox "namanya " & a
r = InputBox("tempat lahir?")
MsgBox "ha???" & r
w = InputBox("no.identitas")
MsgBox "owwww " & w
h = InputBox("jenis kelamin")
MsgBox "oalah " & h
End Sub


Sub konversi()
c = InputBox("masukan suhu dalam celcius")
r = 9 / 5 * c + 32
f = 4 / 5 * c
MsgBox "suhu dalam reamur:" & r
MsgBox "suhu dalam fahrenheid:" & f
End Sub

Tidak ada komentar: