JS

Arrays in JavaScript - Declare and initialize an a...

2.

Which of the following is the correct way to declare an array in JavaScript and initialize it with values?

var arr = [1, 2, 3];

var arr = array[1, 2, 3];

var arr = [1, 2, 3,];

var arr = {1, 2, 3};