Write a VB(visual basic 6.0) program to find factorial number

Write a VB(visual basic 6.0) program to find factorial number

Private Sub Command1_Click()

Dim j, i as Integer

i = CInt(Text1.Text)

Label2.Caption = facts(i)

End Sub

Private Function facts(i)

F = 1

For j = 1 To i

F = F * j

facts = F

Next j


End Function

One Comment

Add a Comment

Your email address will not be published. Required fields are marked *

buy cialis 60 mg online sixteen − seven =