Curioustab
Aptitude
General Knowledge
Verbal Reasoning
Computer Science
Interview
Aptitude
General Knowledge
Verbal Reasoning
Computer Science
Interview
Home
»
C++ Programming
»
Constructors and Destructors
Which of the following statement is incorrect?
Constructor is a member function of the class.
The compiler always provides a zero argument constructor.
It is necessary that a constructor in a class should always be public.
Both B and C.
Correct Answer:
Both B and C.
← Previous Question
Next Question→
More Questions from
Constructors and Destructors
What happens when a class with parameterized constructors and having no default constructor is used in a program and we create an object that needs a zero-argument constructor?
A function with the same name as the class, but preceded with a tilde character (~) is called __________ of that class.
A union that has no constructor can be initialized with another union of __________ type.
If the copy constructor receives its arguments by value, the copy constructor would
Copy constructor must receive its arguments by __________ .
__________ used to make a copy of one class object from another class object of the same class type.
A __________ is a constructor that either has no parameters, or if it has parameters, all the parameters have default values.
Which of the following statement is correct about constructors?
Constructors __________ to allow different approaches of object construction.
How many default constructors per class are possible?
Discussion & Comments
No comments yet. Be the first to comment!
Name:
Comment:
Post Comment
Join Discussion
Discussion & Comments