9 Getting IN-timate


#1



9 Getting IN-timate


No error message, but why does the output also include fullName?
fullName
mayor
population
boroughs


var nyc = {
    fullName: "New York City",
    mayor: "Bill de Blasio",
    population: 8000000,
    boroughs: 5
};

// "for in" cycles through an enumerable properties of an object
for(var property in nyc){
console.log(property);
}


#2

uploaded wrong example - how do I delete this post??


#3

you can't unfortunately. But yo can edit it! Just go down to the bottom right corner of your post and click the pencil icon!:slight_smile: