15/17


#1

Having trouble with this one - embedding an object with the array... Error says unexpected token ";", expected "}" to end a object literal. Help would be appreciated!

var myObj = {
name: "Carl";
age: 27
};

myLife = [myObj];
var newArray = [[1,1,1], [myLife]];


#2

var myObj = {
name: "Carl";
age: 27
};

myLife = [myObj];
var newArray = [[1,1,1], [myLife]];

name: "Carl"; Remove the semi colon and replace it with a colon and it will run fine.
So it would be this.

var myObj = {
name: "Carl",
age: 27
};

myLife = [myObj];
var newArray = [[1,1,1], [myLife]];