soft code guru
free online programming lessons
Thursday, 11 October 2012
Finding average of three values
Private Sub Command1_Click()
Dim M1, M2, M3, avg, tot As Integer
M1 = Val(Text2.Text)
M2 = Val(Text3.Text)
M3 = Val(Text4.Text)
tot = Val(M1 + M2 + M3)
avg = tot / 3
Text5.Text = avg
End Sub
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment