Which of the following type of constructors (in C++) does NOT accept parameters?
2022
Which of the following type of constructors (in C++) does NOT accept parameters?
- A.
Default constructor
- B.
Dynamic constructor
- C.
Parameterised constructor
- D.
Copy constructor
Attempted by 188 students.
Show answer & explanation
Correct answer: A
A default constructor in C++ is defined as a constructor that can be called without any arguments. While parameterized constructors require specific input values and copy constructors take an object reference, the default constructor initializes objects without external parameters.