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...

write a vb script to display first 5 odd numbers from 1 to 100

Answer Posted / psri

dim a(50)
j=0
for i = 1 to 100

if (i mod 2) <> 0 then
a(j)=i
j=j+1
cnt=cnt+1
End if
next
msgbox "The odd no is "& join(a) &"The total no of odd no's
is"&cnt

Is This Answer Correct ?    2 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to Import data from a file (file is on the desktop) to the data table

1972


Plzzzzzzz can any one tell me which is the best institute in hyderabad for learing VBScript. plz do answer guys its urgent plzzzzzzz. thanks in advance.

2169


what do you mean .ota mobile format

2453


Mention how to access array data?

942


What aspects of vbscript make it safe so that a web page using vbscript cannot destroy or corrupt information on a user's computer?

1037


Mention what is vbscript?

1076


how to check whether link is disabled in QTP??

6076


how to increasing the numbers in a given text box please write a vb script

2189


Can any one provide code for Mid(string,start[,length]). I have been asked to write code for Mid(). i.e We need to define our own function say MyMid() which should behave same like built-in Mid function

2402


Which function is used to perform string comparison?

1097


can anyone tell me the procedure of interview held in applabs

2159


What is the purpose of drive object of scripting.filesystemobject class in vbscript?

985


How will you get a combined string from array of string in vbscript?

921


Can we create Crystal Report object in QTP?If yes then what it is and what are its various properties?

3427


How will you release the memory acquired by an array variable in vbscript?

1190