How to get 120 using 5 zeroes, you can use any operator(+,
*, /...) in qtp.
Answer Posted / testengineer
Option Explicit
Dim temp,Factorial,i,j,k,x
temp=0
Factorial = 1
For i=1 to 5 step 1
x= Inputbox ("Enter a No. :") '(Enter Zero for
Five Times)
For j=x to 1 Step -1
Factorial=Factorial*j
Next
temp = temp+Factorial
Next
For k=temp to 1 Step -1
Factorial=Factorial*k
Next
Msgbox Factorial
| Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
How will you get the largest subscript of an array in vbscript?
Develop a parameterized action that accomplishes the following a. Launch a browser of users choice ( example : IE, chrome etc) b. Open up a search engine (Google, Bing etc) c. Perform a search d. Click a particular link depending on the user’s choice ( 1st , 2nd or third link)
write a function to read the items from combobox of Flight reservation & save in excel (QTP)??
Hai this is sheik, i want to learn VB scripts for web application pls guide me what are all basic things need to know to learn VB scripts in web application.
Hi Friends my Question is very simple,in Manual testing when we click on a hyper link it directs us to the relavent page or it re-directs us to the current page,so there we can easily write testcase but same thing if we do in automation script using QTP & need to generate report using Reporter.report event how we will do it?thanks in advance...
Differentiate javascript and vbscript?
can anyone tell me the procedure of interview held in applabs
What is the purpose of folders object of scripting.filesystemobject class in vbscript?
Which respective symbols are used to separate a line and to break the lengthy statement into multiple statements in the vbscript language?
Explain the support of asp for vb script functionality?
How can you create a file object to work with the files in the vbscript language?
what is inner join? what is outer join? what is a constraint? tell me about rdbms? tell me about acid properties?
How strcomp function works?
What are class variables?
How to identify column in VSFlexgrid? My VSFlexgrid window is identified as 'Active X Control'