Creating an Array :
Using an array literal is the easiest way to create an array.
const array_name = [item1, item2, item3, ...];
As you can see the above syntax values are contained inside the [ ], and separated by a comma (,).
An example is given below
const fruits = ["mango", "orange", "banana", "grapes" ];
Spaces and line breaks are not important, a declaration can span multiple lines.
const fruits = [ "mango", "orange", "grapes" ];
You can also create an empty array and then you can provide the elements of an array.
const fruits = ; fruits  = "mango"; fruits  = "orange"; fruits  = "grapes";
const fruits = new Array("mango", "orange", "grapes");
The above two examples do exactly the same so no need to use the new Array().
For simplicity, and readability use the array literal method.
Access an Array Elements
You can access the array elements by using the index number
const fruits = ["mango", "orange", "grapes"]; let fruits = ; //OrangeArray indexes start with 0,  is the first element, and  is the second element.
Changing the Array Elements
The below given example changes the element of a given array.
const fruits = ["mango", "orange", "grapes"]; let fruits = "banana";