C++ Programming - Constructors and Destructors - Discussion

Discussion Forum : Constructors and Destructors - General Questions (Q.No. 5)
For automatic objects, constructors and destructors are called each time the objects
enter and leave scope
inherit parent class
are constructed
are destroyed
Answer: Option
No answer description is available. Let's discuss.
24 comments Page 1 of 3.

Sagar said:   2 years ago
When object is created the constructor is called automatically, and when we deal with the local variables they are created in the stack.

Shree said:   6 years ago
Thanks for the explanation. It is very useful to understand the concept.

Shyam biradar said:   7 years ago
Automatic objects means local variables which are created in stackframe.

So now, you visualize what happens to local variables when a stack frame is created and when its destroyed.

Prabhas sagar said:   8 years ago
What are automatic objects please explain in detailed?

Dhivya said:   8 years ago
I need clear answer with explanation.

Shital Jawale said:   9 years ago
When object is created the call goes automatically to the constructor.

Shital Jawale said:   9 years ago
When object is created the constructor will automatically called.

Kanha said:   10 years ago
Automatic object is local object of any function like "this".

Viknesh said:   10 years ago
An automatic object is not a dummy argument. An automatic object always has the controlled automatic storage class.

Ganesh said:   10 years ago
That is correct automatic object means Constructor can not need to called by using object.

Post your comments here:

Your comments will be displayed after verification.