Question: T This problem is in c++ The following class keeps track of how much of a memory block (say. 512 bytes) is being used. It

T

T This problem is in c++ The following class keeps track of

This problem is in c++

The following class keeps track of how much of a memory block (say. 512 bytes) is being used. It contains a pointer that will point to the first element of an array. This array will be of an arbitrary size. There is a second integer to hold the size (as given by the user at the time of instantiation). Each element of the array is a block, and the number kept in that element is the bytes of that block used. class BleckUsage private: int* blocks: int numBlocss public: // constructors (default, one arg, and copy.) // destructor // Member function ) If this is in the Class Specification file(lackUsageh), write the function definitions that would be in the Class Implementation file (BlockUsage.cpp). For the default constructor, NULL and 0 are appropriate default values. i) Why must the parameter of the copy constructor be of type constant reference

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!