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
Write program for identifyig duplicates in flight Departing from and Arriving in mercury tours(web application).
How can you destroy an object in vbscript?
What is the use of the date function in the vbscript language?
wat is the com(common object model)object for mozilla firefox???????plz if any one know the exact answer....reply me......
Mention what is the main difference between function and sub-procedure?
We have 1 web page with names column. I am giving the Service Providers1,2,3.... @ that time dynamically some no of names are displaying in the webpage and The Pop up windows are opening(No.of Pop Up windows=No.of Names). The names may be diffar for each and every Service Provders (Dynamically) How can we handle the Dynamic values?
How will you convert a given number to long in vbscript?
I have attended Anovatek Software QTP interview. They will give us computer and one web based application with QTP. We have to automate some records (already updated records or new records) using QTP Data driven testing. But we should use for loop? Can any one know how to do data driven testing using For loop?
Which object provide information about a single runtime error in a vbscript?
Set srchobj=Description.Create() srchobj("type").value="text" srchobj("name").value="q" srchobj("html tag").value="input" browser("micclass:=google").Page("micclass:=google").webedit (srchobj).Set "qtp" what's wrong in my code pls tell me ? the above code working fine and i got my result pass,now i am trying to run the program it shows general run time error why?pls help me i am in learning stage ?
Mention what is the use of option explicit in vbscript?
how to comvert 120 into one hunderd twenty rupees only and vice varsa
Which event is triggered when mouse focus comes out of an element in the vbscript language?
If else for do while select in vb script?
Explain sga memory structures?