0

What should i do to force this code to print an age?

https://code.sololearn.com/W43sUSNLBNdj/?ref=app

28th May 2020, 4:09 PM
LordOfBrightnes
2 Respuestas
+ 2
You should create a person object. let person1 = new person("PouryaDB",20); // To print age document.write(person1.age); // To print yearOfBirth document.write(person1.yearOfBirth());
28th May 2020, 4:42 PM
Avinesh
Avinesh - avatar
0
Thx
28th May 2020, 4:42 PM
LordOfBrightnes