Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

C++ Linked List- Create a basic class called Phone The class must have the following attributes 3 integers Area_code, exchange & number 1 boolean unlisted

C++ Linked List-

Create a basic class called Phone

The class must have the following attributes

3 integers Area_code, exchange & number

1 boolean unlisted

You will have two constructors for this class one parameterized and the non-parameterized constructor that sets all values to 0 or false

make sure the AreaCode and Exchange are between 0 and 999

make sure that the number is between 0 and 9999

There must be the following behaviors

setPhone( ) that has all values passed

pntPhone() That would display the number in the format Given the Area_code=269, exchange=555, number=1212 unlisted=true (269)555-1212 is unlisted Given the Area_code=269, exchange=555, number=1234 unlisted=false (269)555-1234 is listed

Have the object overloaded<< to do the same as pntPhone() above

dial() the prints to the screen the number only such as 2695551234

unlist() that will make the number unlisted

list() that will make the number listed

Add to the Phone class above the pointer attributes to be able to dynamically allocate the phone records and store them in a linked list

It is okay for the attributes to be publicly accessible for this lab.

You will want to interactively enter the values. Stop adding to the list when the area code of the phone number is 555.

After the stop entry of 555 has been entered print the list in order of entry

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_2

Step: 3

blur-text-image_3

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

Graph Databases In Action

Authors: Dave Bechberger, Josh Perryman

1st Edition

1617296376, 978-1617296376

More Books

Students also viewed these Databases questions

Question

2 0 . Statements inside loops are _ _ _ _ _ _ _ _ _ _ .

Answered: 1 week ago

Question

2. What do you believe is at the root of the problem?

Answered: 1 week ago