Question: c++ use operator overloading for solving the following two question Question 1 [40 Marks): Complete the definition of the class given below such that the

c++ use operator overloading for solving the following two question c++ use operator overloading for solving the following two question Question 1

Question 1 [40 Marks): Complete the definition of the class given below such that the main program runs successfully. Make sure that your program doesn't consume extra memory space and it should not leak any memory. class Sett private: int* elements; //To save elements of a Set int size; //Total number of elements in a Set }; void main() { int arri[] = {10,20,30,40); Set si(arri , 4); //Creates a Set with elements of arr1 and size = 4 int arr2[] = {5,15,55}; Set s2(arr2 , 3);//Creates a Set with elements of arr2 and size = 3 cout

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!