11/17 missing ' ' before statement


#1
var me = myObj{};
myObj.name = "Stephen";
myObj.age = 14;

This is the code I have, I get "SyntaxError: missing before statement" and I can't figure out what's wrong with it.
Any help would be appreciated.


#2

Hi @stevew1113
You have to change your code like this :

var myObj = {};
myObj.name = "Stephen";
myObj.age = 14;

#3
var me = {};
me.name = "Stephen";
me.age = 14;

This is the code I tried, I also tried your code but I keep getting "

Oops, try again.
Did you create your object using the object constructor?

"


#4

Try this out..

var myObj = {};
var myObj = new Object ();
myObj.name = "Stephen";
myObj.age = 14;