View Single Post
  #2   Spotlight this post!  
Unread 06-03-2006, 21:56
BotLobsta BotLobsta is offline
Registered User
FRC #1477
 
Join Date: Jan 2006
Location: Texas
Posts: 4
BotLobsta is an unknown quantity at this point
Re: Visual Basic. Using a loop to solve the cosine function.

One thing that I noticed is that in the factorial loop, you dont want to start at n-1, you want to start at FactNum - 1. What you are doing now in that nested for loop is (n-1)!*FactNum. This will only give you the correct value when Counter = n/2.