explain the memory allocation of an object
Answers
Answered by
1
Answer:
Memory Allocation for Objects
Memory Allocation for ObjectsThe memory space is allocated to the data members of a class only when an object of the class is declared, and not when the data members are declared inside the class.
Answered by
0
Answer:
The memory allocation for an object can be static or dynamic. The static memory allocation is when an object is declared directly without using any function usually. And dynamic allocation is when we use some dynamic allocation function to allocate memory for data member of an object
Similar questions