Aptitude | JavaScript Course Quiz 3 | Question 3

Given a collection of artists and lists of their songs, would you store the artist-song-list pairs in an Object or an Array?
(A) Object
(B) Array
(C) Function
(D) None of the above


Answer: (A)

Explanation: If you want to store a bunch of numbers or a list of objects of the same type, use an array. But here we have to store list of their strongs as per their name so we will use Object.

Quiz of this Question



My Personal Notes arrow_drop_up


Article Tags :

Be the First to upvote.


Please write to us at contribute@geeksforgeeks.org to report any issue with the above content.

About immukul

Executive Software Developer at Cavisson Systems