How to find duplicates in an array and remove them
efficiently?
Answer Posted / crazy boy
**How to find duplicates in an array and remove them efficiently?
=================================================
dim a(4)
a(0)=10
a(1)=20
a(2)=10
a(3)=20
a(4)=50
for i=0 to ubound(a)
for j=i+1 to ubound(a)
if a(i)=a(j) then
a(i) =empty
end if
next
next
for i=0 to ubound(a)
if a(i)<>"" then
msgbox a(i)
end if
next
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
How many number of actions possible in qtp?
explain abt dyanamic changing object with example?
How reliable are the site's Internet connections required to be? And how does that affect backup system or redundant connection requirements and testing?
Presently i am working on QTP 8.2 Version,i want to know features in 9.2 version, because i have not sufficient time to put the effort on the 9.2 version
QTP 10.0 is not identifying web objects for IE 8.it is identifying like winObject.I installed HP patch QTPWEB_00037.Still getting issue
Why qtp always start action1 and does not start action?
What is ObjectParamater?
What is qtpro? What is a quick test professional?
what is actually contain test report? can anybody post the test report
what is meant by source control?
Hi All, I have QTP installed on my machine but the application under test (AUT) is on remote desktop.My scenarios is like that,it should contain following steps. 1)Automatically it should click on start and then on remote desktop connection. 2)it should enter the IP address and then connect to remote desktop. 3)and then it should be able to record the application in remote machine and then run it also. Can somebody tell me how to record the application which is in remote machine.
HOw to add the recovery file at runtime to the test file .
How should I click on the right click menu objects When I trying to add the object properties to the OR.It is showing only Window(Window).Not all the objects of the window. Also while recording I found No script. How to solve this>.
Could anyone help me for the below scenario: i am using the descriptive programming for my account, in which we have to generate the contract in the MS-word. when i generate this doc, we need to click on enable macros to continue further. but i am unable to make qtp to click on this. if anybody faced the problem like this??? pls help to get it resolved? Thanks in advance
How to do call a output parameter from one action to another action??/