Skip to content
Related Articles

Related Articles

Improve Article
Save Article
Like Article

Web technologies Questions | JavaScript Course Quiz 1 | Question 37

  • Last Updated : 26 Aug, 2021

Which of the following is the correct syntax for array declaration
(A) const arr={1,2,3,4}
(B) const arr=[1,2,3,4]
(C) Both a and b
(D) None of the above

Answer: (B)

Explanation: Arrays in javascript are declared using ‘[]’ square brackets

Quiz of this Question
Please comment below if you find anything wrong in the above post

My Personal Notes arrow_drop_up
Recommended Articles
Page :

Start Your Coding Journey Now!