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 can I define an array in JavaScript?

Answers were Sorted based on User's Feedback



How can I define an array in JavaScript?..

Answer / shini nino

var arrQualif=new Array();

Is This Answer Correct ?    30 Yes 10 No

How can I define an array in JavaScript?..

Answer / madhav arora

Arrays can be defined in following three ways :

1. regular method:
ex: var arrayname=new Array();
arrayname[0]="abc";
arrayname[1]="pqr";
arrayname[2]="xyz";

2.condensed method:
ex: var arrayname=new Array("abc","pqr","xyz");

3.literal method:
ex:var arrayname=["abc","pqr","xyz"];

Is This Answer Correct ?    16 Yes 4 No

How can I define an array in JavaScript?..

Answer / hiren garasia

array arrayname=new array[];

Is This Answer Correct ?    17 Yes 11 No

How can I define an array in JavaScript?..

Answer / hiren b garasia

4.dense method:
ex: var days=new
Array('Mon','Tue','Wed','Thus','Fri','Sat','Sun');

Is This Answer Correct ?    5 Yes 4 No

Post New Answer

More JavaScript Interview Questions

What are the advantages of javascript?

0 Answers  


What does it mean in javascript?

0 Answers  


What is the naming conventions for the variables in javascript?

0 Answers  


What does parse Query String return in javascript?

0 Answers   Changepond,


Write a main method that prompts the user to enter the starting population, birth and death rates, and the number of years. The input birth and death rates cannot be negative, the starting population cannot be less than 2, and the number of years greater than 0. If the user enters an invalid value, this program will prompt user to re-enter the value until a valid value has been read. When all input values are valid, call on the methods above to compute estimated population and print result.

0 Answers   Wipro,


What is a closure and why are they so useful to us?

0 Answers  


What are JavaScript types?

11 Answers   Infosys, Satyam,


Should you disable javascript?

0 Answers  


what is the difference between wrappers and primitives es: diff between int i=200 in primitives and integeri = new integer(54)

0 Answers  


What is the real name of JavaScript?

0 Answers  


What is decodeuri() function?

0 Answers  


What is difference between array.splice() and array.slice() method in javascript?

0 Answers  


Categories