What is Constructors and Destructors?
Answers
Answered by
1
who construct the thing is a constructor which destroy is distructor
Answered by
1
Constructors are special class functions which performs initialization of every object. The Compiler calls the Constructor whenever an object is created. Constructors initialize values to object members after storage is allocated to the object.
Whereas, Destructor on the other hand is used to destroy the class object.
Let's start with Constructors first, following is the syntax of defining a constructor function in a class:
please select it in braineist answers
Similar questions