I don't know this lesson so help me out


#1

function person(name, age){
this.Name = "name";
this.Age = "age";
};
// Now we can make an array of people
var family{
var alice = new person("alice", 40),
var bob = new person("bob", 43),
var michelle = new person("michelle", 8),
var timmy = new person("timmy", 6)};

// loop through our new array

family{
    for(var i = 0; i < 3; i++){
 console.log("this.name");
 return i;
}
};

#2

Let's break this code down. The function at the beginning makes it easy to make a new person by typing in their name and age. An array is just something that stores a lot more somethings, and Alice, Bob, Michelle, and Timmy are those somethings. Finally the for loop iterates through the family, printing all of their names. Also, you have something you need to fix. Check out this line:

Get rid of the quotation marks. this.name doesn't need it because it's a placeholder, not a string. Hope it helped! :wink: