Input = 124
output should be 124421
Please do not use any string functions/variables
Answer Posted / anil
input="421"
Dim arr(3)
arr(0)="4"
arr(1)="1"
arr(2)="2"
Set arrlist=CreateObject("system.collections.Arraylist")
For i=0 To UBound(arr)-1
arrlist.add arr(i)
Next
arrlist.sort
For i=0 To UBound(arr)-1
c= arrlist.item(i)
temp=temp&c
next
MsgBox temp&input
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Dear All, I am geting below IE error whilie executing the QTP scripts in Batch mode "Internet Explorer has encountered a problem and needs to close. We are sorry for the inconvenience." can any one suggest me how to resolve this issue . Thanks Balaji
Which command is used for writing text on a page?
hi what is called GUI in QTP 8.2 and how can we test the apllication using GUI?
What are string functions in vbscript?
How can you destroy an object in vbscript?
How to Import data from a file (file is on the desktop) to the data table
What is the main difference between function and sub-procedure?
How to use QTP Object in .vbs(vbscript file) file Ex: Browser().., wait(), exist() and etc...
How are arrays declared in the vbscript language?
How many types of procedures are available in the vbscript language?
What is vbscript?
What is the scope of a constant declared using public?
Explain How do you create a recordset object in vbscript?
Mention what is the technology used by vb script?
Can we create Crystal Report object in QTP?If yes then what it is and what are its various properties?