Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Problem 1 2 3 4 function contact(name, number) { this.name = name; this.number = number; Contact Manager } 6 7 8 9 10 var a

image text in transcribed

Problem 1 2 3 4 function contact(name, number) { this.name = name; this.number = number; Contact Manager } 6 7 8 9 10 var a = new contact("David", 12345); var b = new contact("Amy", 987654321) a.print(); b.print(); You are working on a Contact Manager app. You have created the contact object constructor, which has two arguments, name and number. You need to add a print() method to the object, which will output the contact data to the console in the following format: name: number The given code declares two objects and calls their print() methods. Complete the code by defining the print() method for the objects. Notice the space after the colon, when outputting the contact data

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Databases Illuminated

Authors: Catherine Ricardo

2nd Edition

1449606008, 978-1449606008

More Books

Students also viewed these Databases questions