If an object is declared in a user defined function __________________
(a) Its memory is allocated in stack
(b) Its memory is allocated in heap
(c) Its memory is allocated in HDD
(d) Its memory is allocated in cache
The question was posed to me in a national level competition.
I'm obligated to ask this question of Memory Allocation of Object in section Object of Object Oriented Programming