write a vb script to generate fibonnaci numbers



write a vb script to generate fibonnaci numbers..

Answer / mudaseer

vnum=inputbox("enter a number")
i=0
j=1
vstr=i & "," & j & ","
msgbox vstr
for x=1 to vnum-2
k=i+j
vstr=vstr & k & ","
i=j
j=k
next
msgbox vstr

vnum=inputbox("enter a no")
i=0
j=1
vstr=i & "," & j & ","
msgbox vstr
for x=1 to vnum-2
k=i+j
vstr=vstr & k & ","
i=j
j=k
next
msgbox vstr

Is This Answer Correct ?    3 Yes 1 No

Post New Answer

More VB Script Interview Questions

How do i automate a website www.flyashx.com without having any test cases witin a week time.

0 Answers   Zensar,


In QTP how to insert a data base check point for web based application and simultaneous link to code in expert veiw. hw to retrieve a data(single coulumn from server) that matches with inserted value manually or exported from excel sheet.

2 Answers  


For a webbased application:- what should be code in expert veiw, for retrieving a single column name "username" from a server and checking whether exported "username" from datatable doesn't exist in server. suppose i have saved in excelsheet a username="gayatri" , which is exported, then checked for whether this username "gayatri" exist in server database or not ? if exist then allow to enter new username, which should be again checked for in loop , or else come out of loop and enter a distinct "username". plz let me have this answer in my id gayatrisahooin@hotmail.com

0 Answers  


How to create MSAcess table foriegn key

1 Answers  


I want good books or good sites for scripting.Can any one help me.

0 Answers   Wipro,






how to genarate a random numbers in vb?

2 Answers  


How are values assigned to the variables in the vbscript language?

0 Answers  


I am working on QTP, got struck in one place.. In my application depending upon configuration WebEdit count is increasing/ decreasing.. how to get these webedits..

0 Answers  


How to use QTP Object in .vbs(vbscript file) file Ex: Browser().., wait(), exist() and etc...

0 Answers  


How will you release the memory acquired by an array variable in vbscript?

0 Answers  


how does vb script help in web page designing? explain with example.

0 Answers  


How to write a general script which should does the following a). If a page object is given, it should identify the page object of the corresponding page(site). b). It should identify all the links of that particular page. in QTP tool?

2 Answers   IBM, Infosys, Wipro,


Categories