What is the correct way to write a JavaScript array? - Study24x7
Social learning Network
618 followers study24x7 18 Apr 2019 07:52 PM study24x7 study24x7

What is the correct way to write a JavaScript array?

A

var colors = ["red", "green", "blue"]  

B

var colors = (1:"red", 2:"green", 3:"blue")

C

var colors = 1 = ("red"), 2 = ("green"), 3 = ("blue")

study24x7
Write a comment
Related Questions
500+   more Questions to answer
Most Related Articles