Arrays
An array is an ordered stack of data items called elements. Each element of the array can store its own data, just like a variable. In essence, arrays are a collection of variables. Elements of the array can be of different types (specific to JavaScript).
For example, to create an array type the following:
var myArray = new Array();
For example, to access an array element type the following:
var myVar = myArray[0];
Note the following:
• The first element of an array is 0, not 1. For example the fifth element in an array would be:
var myVar = myArray[4];
• Beans often return a list of data in an array. Looping through or accessing a specific element in the array is often performed.