For example when we write:
int * p = new int[5];
at which memory segment the memory will be allocated?
In C
I know that when we use malloc()
it allocates memory in heap
section but for C++
I am not sure. I read that, for new()
memory allocated from free store and for malloc()
memory allocated from heap on this link.
What is this free store? Is it part of RAM only? Is there any diagram for memory management containing free-store like we have for C?