Creating a new object


#1

Hi, I am stuck with the same exercise, but different problem. When I write the code below, only "28" is being printed when I submit the code. What am I doing wrong? (also not sure if I should post this here or in the separate thread, hope it's fine here).

var myObj = new Object();
myObj.name = "Justyna";
myObj.age = 28;

Thanks for help!


Creating A New Object
#2

Hello!
I think you should change the object into 'me'.
If I am wrong, kindly consult to someone else


#3

if you want to print something, use console.log(), not everything you code has to be printed


#4

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