Step-by-step explanation:
What is constructor?
Constructor is a member function of class, whose name is same as the class.
A constructor is a special type of member function of a class which initializes objects of a class. In C++, Constructor is automatically called when object(instance of class) is created.
Constructor is invoked at the time of object creation. It constructs the values i.e. provides data for the object that is why it is known as constructors.
Constructor does not have a return value, hence they do not have a return type.