Explain the default constructor and destructor, C/C++ Programming

Assignment Help:

The default Constructor and Destructor

If you fail to write a constructor and destructor function,  the compiler automatically supplies them for you. These functions have public access and essentially do nothing useful. If you were to write these functions yourselves, this would look like:

                class employee

                 {

                public :

                                employee()

                                                 {

                                                 }

 

                                ~employee();

                                 {

                                 }

    };

 


Related Discussions:- Explain the default constructor and destructor

Define statements to define the constants, the problem description. The ...

the problem description. The order of the C Program should be as follows: Variables and constants Use #define statements to define the constants. Use arr

Is there any difficulty with the following : char*a=null; , Is there any di...

Is there any difficulty with the following : char*a=NULL; char& p = *a;? A: The result is indeterminate. You must never do this. A reference has to always refer to some object.

Loops, how many types of loops are there and whay are they and what are its...

how many types of loops are there and whay are they and what are its uses

How, how to program?

how to program?

Euclidean Algorithm , how can I find the GCD of 2 given numbers using Eucli...

how can I find the GCD of 2 given numbers using Euclidean Algorithm ?

#otto cycle, To get the efficiency of Otto cycle by C/C++.

To get the efficiency of Otto cycle by C/C++.

Asdas, Ask question #Miniasdasmum 100 words accepted#

Ask question #Miniasdasmum 100 words accepted#

Queue - c++ program, Queue - C++ program: Write a program to show the ...

Queue - C++ program: Write a program to show the basic operations on queue. namespace stack {  const int max_size = 200;  char v(max_size);  int top=0;  void pu

C program to convert time in 24 hour format to 12., Aim: To implement a pr...

Aim: To implement a program to convert time in 24 hour format to 12 hour format. Code:                       #include #include #include class time24 {

Functions overloading, Functions Overloading This a capability in which...

Functions Overloading This a capability in which a C++ program can have several functions performing similar tasks on different data types. When an overloaded function is calle

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd