List'em all


#1


https://www.codecademy.com/courses/javascript-beginner-en-3bmfN/0/6?curriculum_id=506324b3a7dffd00020bf661


I'm not sure what i'm doing wrong here? i keep getting Oops, try again. It looks like your list function isn't printing the right output. Would love some help please :slight_smile:


var friends = {
    bill: {
        firstName: 'Bill',
        lastName: 'Gates',
        number: '1800 393 987',
        address: ['Microsoft HQ', 'Murica', '22093']
    },
    steve: {
        firstName: 'Steve',
        lastName: 'Jobs',
        number: '1800 565 478',
        address: ['Apple HQ', 'Murica', '20193']
    },
    
};

var list = function(param) {
    for(var key in friends) {
        console.log(friends);
    }
};
list(friends);


#2

Your function takes an argument but doesn't do anything with it, doesn't that seem a little weird?


#3

Omg thank you, i figured it out


#4

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