Sunday, December 27, 2009

Coding at visual basic programming?

please give me the code of Visual Basic program that finds the sum of the series:





1+1/2+1/3+1/4+...........+1/100





please give me the code... email the code at emylcleffjules_gregorio@yahoo.comCoding at visual basic programming?
Private Sub Command1_Click()


Dim x As Integer


Dim y As Double


x = 1


Do While x %26lt;= 100


y = y + (1 / x)


x = x + 1


Loop


Text1.Text = y


End Sub





after run the code the text box will display the sum of your calculation
  • oil production
  • cream
  • medicine cream
  • motorcycle oil
  • No comments:

    Post a Comment