. Program for sorting of numbers in vb script?
Answer Posted / amrita
We will assign the series of numbers in array then will the sort that. Below is the code:
a = array(3,4,9,2,7,1)
For i=0 to ubound(a)
For j=0 to ubound(a)
If strComp(a(i),a(j),1) < 0 Then
temp = a(i)
a(i) = a(j)
a(j) = temp
End If
Next
Next
For i=0 to ubound(a)
print a(i)
'It will print 1,2,3,4,7,9
Next
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Does VB/Win make standalone .EXE files?
did any one attended interview in applabs if you had gone through plz tell me the procedure
Which function allows you to instantiate an object given its programmatic identifier or progid?
what is the difference between modular and data and keyword driven framework
What are the uses of vb script?
What's the difference between vbscript and vb.net?
What is dictionary object in vbscript? Explain?
What is the use of the ‘open’ method to work with the database in the vbscript language and what connection string is passed in the same and what is its usage?
What is vbscript language used for and which earlier language is it modeled upon?
Explain the arrays in vb script?
how to increase the values in text box in a given text box increament by two values by clicking on button
Could Anybody Please tell me What is the script for Find 3rd Largest element in the Array without using a SORT function int Find(int arr[], int size); Thanks in Advance..
Hi Friends, I have an issue like the describe below: I'm using QTP and I'm testing on SharePoint. As you knoe, SharePoint has a customize function for user, so that, If I add an object Web Table at the first time, that object was recognized by "index" and "html tag", after that, if someone change the display of web part, the "Index" of my object was changed as well and QTP unable to select that Web Table. Can you guide me how to identify or anyway to keep that Web Table object as unique object? Thanks a lot.
How are values assigned to the variables in the vbscript language?
Explain about arrays in vb script?