constructors

mcqspedia.com has 2 Question/Answers about Topic constructors

A constructor is a member function that is called automatically when

A constructor is a member function that is called automatically when
  • A. an object is declared
  • B. an function is created
  • C. an function is accessed
  • D. All of them
  • Correct Answer: Option A

A constructor has

A constructor has
  • A. Return type integer
  • B. Return type char
  • C. No return type
  • D. Return type Boolean
  • Correct Answer: Option C