|
-
Nov 22nd, 1999, 04:06 AM
#4
I think this should help you
if for some reason it doesn't work at least the F function has the correct algorithm to get what you need.
public sub main()
dim iC,iD as integer
ic=inputbox("Enter the term number you want to get the value of...")
iD=F(iC)
msgbox iD
end sub
private function F(n as integer) as integer
if n=1 or n=2 then
F=1
else
F=F(n-1) + F(n-2)
end if
end function
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|