Answered step by step
Verified Expert Solution
Question
1 Approved Answer
2. (10 Points) Write a constructor function for a Book with title, author and length properties. Book objects should also have a method called print
2. (10 Points) Write a constructor function for a Book with title, author and length properties. Book objects should also have a method called print that prints all three properties. Do NOT use the ECMAScript 2015 Class Keyword. var mobyDick-new Book 'Moby Dick', 'Herman Melville', 882); mobyDick-print) 1I Moby Dick by Herman Melville, is 882 pages long
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started