Stuck at adding an object in an array. Any suggestions


#1



Check out my code below.

var fruits = {
name: "bananas",
country: "dominican republic"
}

var myArray = [ [1],[true], ["Nice", "business", "structure"], [fruits] ];

The console is asking me if the first element of the array is a number. How come it in seeing my first element?

Thanks!


Replace this line with your code.


#2

Your first element is an array.

That array's first element is a number.


#3

lol. yes! True. Sometime all a problem needs is a simple solution.

Thx cadecodes!