Introduction to objects Loop the Loop


#1


https://www.codecademy.com/courses/spencer-sandbox/4/2?curriculum


these are the errors my code gives me Ive spent a while trying to debug it so any help is greatly appreciated:)
"Make sure to log to the console the name of each object"
the array literal notation [] is preferable


// Our Person constructor
function Person (name, age) {
this.name = name;
this.age = age;
}

// Now we can make an array of people
var family = new Array();
family[0] = new Person("alice", 40);
family[1] = new Person("bob", 42);
family[2] = new Person("michelle", 8);
family[3] = new Person("timmy", 6);

// loop through our new array
for(var i; i < family.length; i++) {
  console.log(family[i].name);
}


#2

here:

for(var i

i should have an initialize value


#3

great works now thanks!


#4