Pls Am really stuck pls solve


#1

https://www.codecademy.com/courses/building-an-address-book/0/3?curriculum_id=506324b3a7dffd00020bf661#

var bob = {
firstName: "Bob",
lastName: "Jones",
phoneNumber: "(650) 777-7777",
email: "bob.jones@example.com"
};

var mary = {
firstName: "Mary",
lastName: "Johnson",
phoneNumber: "(650) 888-8888",
email: "mary.johnson@example.com"
};

var contacts = [bob, mary];

// printPerson added here
function printPerson (person){
console.log(person.firsName + "" + person.lastName)
}
function list() {
for( i = 0; i < (contacts.length); i++)
printPerson(contacts[i]);
}
list;


Replace this line with your code.


#2

a function call is function name + parentheses:

list();

inside your printPerson function you misspelled firstName, and there is no space between first and last name


#3

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.