how can arrays be created in HTML give example
Answers
Answered by
2
Arrays are lists of any kind of data, including other arrays. Each item in the array has an index — a number — which can be used to retrieve an elementfrom the array.

The indices start at 0; that is, the first element in the array has the index 0, and subsequent elements have incrementally increasing indices, so the last element in the array has an index one less than the length of the array.
In JavaScript, you create an array using the array-literal syntax:
var emptyArray = []; var shoppingList = ['Milk', 'Bread', 'Beans'];
You retrieve a specific element from an array using square bracket syntax:
please add brainlist

The indices start at 0; that is, the first element in the array has the index 0, and subsequent elements have incrementally increasing indices, so the last element in the array has an index one less than the length of the array.
In JavaScript, you create an array using the array-literal syntax:
var emptyArray = []; var shoppingList = ['Milk', 'Bread', 'Beans'];
You retrieve a specific element from an array using square bracket syntax:
please add brainlist
Similar questions
Computer Science,
7 months ago
Social Sciences,
1 year ago
Chemistry,
1 year ago
Chemistry,
1 year ago
Math,
1 year ago