A member function that is used to initialize the class members is known as a _______. 

  • initializor 
  • starter 
  • setter 
  • constructor
In C++, a constructor is a special member function that is automatically called when an object is instantiated. Its primary purpose is to initialize the object's attributes.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *