Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


how to find greatest of n numbers!

Answers were Sorted based on User's Feedback



how to find greatest of n numbers!..

Answer / mudaseer

dim varr(4),vhigh
for i=0 to 4 step 1
varr(i)=cint(inputbox("enter the value"))
next
vhigh=varr(0)
for i=1 to 4 step 1
if varr(i)>vhigh then
vhigh=varr(i)
end if
next
msgbox vhigh

Is This Answer Correct ?    8 Yes 2 No

how to find greatest of n numbers!..

Answer / raju

dim i, lar, j, a()
i=Cint(Inputbox("Enter the value how many value to be enter"))
for j=1 to i
ReDim a(i)
a(j)=inputbox("enter the numbers")
Next
lar=a(0)
for j=1 to i
If a(j)>lar Then
lar=a(j)
End IF
Next
msgbox "Largest Number is" & lar

Is This Answer Correct ?    8 Yes 4 No

how to find greatest of n numbers!..

Answer / venkatesh

option explicit
dim myarray,max,i
myarray = array( 34,23,45,67,12 )
max=myarray(0)
for i=0 to ubound(myarray)
if max < myarray(i) then
max=myarray(i)
end if
next
msgbox "max number is : "&max

Is This Answer Correct ?    5 Yes 5 No

Post New Answer

More VB Script Interview Questions

How to find the font in qtp. Scenario:After entering the username and passwd you will be navigate into the "welcome:Username" page.Now I want to extarct font for this message.

0 Answers   GE, iGate,


How regexp.execute method works?

0 Answers  


write a vb script to rename a folder from tree4 to tree7

3 Answers  


am giving to one number u can set into that in date format.u can use any methods

1 Answers   HP,


Which function is used to perform string comparison?

0 Answers  


Difference between Function and Sub routine?

0 Answers   Polaris,


What is the use of "Option Explicit"?

2 Answers  


write a program to display configuration of a local system with the help of vb script.

0 Answers  


How will you reverse a string in vbscript?

0 Answers  


write a vb script to display factorial of a number using function

1 Answers  


why variable name should not exceed 255 characters?

0 Answers  


How can I get the value of an object property or variable in another frame?

1 Answers   Citi Bank,


Categories