Question: C++ Create a NumberList class which has a dynamic integer array with size initially unknown. Create an object from this class, ask the user for

C++

Create a NumberList class which has a dynamic integer array with size initially unknown. Create an object from this class, ask the user for size of the array in the object, dynamically create it and fill it with random numbers. Then create two more objects and set them to the first object. Replace all odd numbers with their negatives in the second object and replace all even numbers with their negatives in the third object. Print all three arrays on screen. Copy constructor is needed for this question.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!