Thanks for your latest comments about my code. I appreciate such small corrections a lot.
I did my homework.
The stack is the 'regular' memory where variables are stored. The heap is the memory between the program code and the stack. It is FINITE in size. That is why you mentioned not to create variables in the heap?
I saw the difference and learned that created variables in heap must also be destroyed using delete.
Is there any other reason why not to use the heap for regular variables?






Reply With Quote

Bookmarks