Displaying People


It looks 100 percent correct and I can't see what the problem is.
Error: It looks like your function didn't log "Bob Jones" to the console. Did you remember to call your function on bob?

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
var printPerson = function(person) {
    console.log(person.firstName + "" + person.lastName);


You're missing the space within the quotation marks within your console.log..

" "

Check your output and you'll see with your code it displays as


rather than

Bob Jones
Mary Johnson


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