What is a Default constructor?



What is a Default constructor?..

Answer / munendra kumar

A constructor that has no arguments.

If you don't code one, the compiler provides one if there are no other constructors. If you are going to instantiate an array of objects of the class, the class must have a default constructor.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C++ General Interview Questions

What is Object Oriented programming.what is the difference between C++ and C?

8 Answers   Infosys,


what is static function

2 Answers   Patni,


Suppose that data is an array of 1000 integers. Write a single function call that will sort the 100 elements data [222] through data [321].

0 Answers  


What are structures and unions?

0 Answers  


Explain linear search.

0 Answers  


what is oops and list its features in c++?

0 Answers  


Is overriding possible in c++?

0 Answers  


What is object slicing and how can we prevent it?

2 Answers   Tech Mahindra,


What is a 'pure' virtual function and what's its use?

1 Answers  


Write a program which uses Command Line Arguments

0 Answers  


What is flush c++?

0 Answers  


Write a program to show polymorphism in C++?

0 Answers   Impetus, Verifone,


Categories