13. Introduction to Objects I Help please


#1


I can't figure out what's wrong with this code.


Oops, try again. There was a problem with your syntax.


var snoopy = {
    species = "beagle",
    age = 10
};
var buddy = new Object();
    buddy.species= "golden retriever";
    buddy.age = 5;


#2

try replacing the "=" in your keys inside your object literal with a ":"


#3

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