I have two piece of code that creates an A object
A* a=new A();
AND
A b;
A *c=&b;
The question is: someone says "objects are always allocated on heap"?
Is it true even declare it on stack?(Code 1)
Note: I am referring to the actual memory allocation. I know object 'b' will be
cleared when it goes out the the scope. But when it is still in scope, where does the
memory of 'b' actually reside?