answersLogoWhite

0


Best Answer

the copy constructor

User Avatar

Wiki User

12y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: When a class uses dynamic memory what member function should be provided by class?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

What are the different function used for dynamic memory allocation?

alloc :- to allocate memory. calloc :- to free the memory.


Why main memory use dynamic memory rather than static memory?

Dynamic memory changes and static stays the same.


Difference between dynamic and static memory?

dynamic is the study of motin,while static is at rest it means that the memory which is used at motin time as by usic calloc,mallaoc,free function ,on the other hand static is the memory which only used at compile time or at the time of work in during progrmming,static memory has drawback ,the drawback is that in this memory ware unable to use the excess memory as we allocate already to cover or improvre this type of problem we use dynamic memory allocation.


What is the full form of dram?

DRAM is dynamic RAM or, if you prefer, dynamic random-access memory.


Which memory is difficult to interface with processor?

dynamic memory


What is static and dynamic memory?

A computer is built to contain two kinds of memory. There is static memory, which stays in the computer after it is powered off. Then there is dynamic memory, which is memory that is only accessible while the computer is on. The hard drive is an example of static memory, while RAM is an example of dynamic memory.


What is dynamic mamory?

Dynamic memory refers to memory that is allocated and deallocated during program execution, as opposed to static memory which is allocated at compile time. In C and C++, dynamic memory allocation is done using functions like malloc() and free(), allowing for flexibility in managing memory resources at runtime. However, improper use of dynamic memory can lead to memory leaks or segmentation faults.


What is the maximum size of memory available for dynamic memory allocation?

The maximum memory that can be dynamically allocated depends on the size of the heap memory. Dynamic blocks of memory can be allocated in system heap until it is not full.


Stack can be described as a pointer Explain?

Stack is also dynamic memory, without the hassle. Dynamic memory uses pointers to check its value, free the memory, etc.


C plus plus uses dynamic memory management?

No, C++ does not use dynamic memory management. The programmer is entirely responsible for releasing dynamic memory when it is no longer required. When static objects fall from scope, their destructors are called automatically, but there is no automatic garbage collection for dynamic objects. Allocated memory remains allocated until the programmer manually releases it, or the thread that owns the memory is terminated.


What are the problem associated with dynamic memory allocation?

Not freeing it when you no longer need the memory.


What is the Conceptual Memory Map of a C Program?

C++ has 4 distinct regions for memory distribution Stack : This region is used for function calls' return addresses , arguments and local variables Heap : This region is for dynamic allocation of memory (dynamic variables created on run time use this memory , aka RAM) Global Variables : This is used for global variables defined by the programmer Program Code : This region is for the program code.