C++ Programming - Constructors and Destructors - Discussion

Discussion Forum : Constructors and Destructors - Programs (Q.No. 10)
10.
What is the technical word for the function ~IndiaBix() defined in the following program?
#include<iostream.h> 
class IndiaBix
{
    int x, y; 
    public:
    IndiaBix(int xx = 10, int yy = 20 )
    {
        x = xx; 
        y = yy;
    }
    void Display()
    {
        cout<< x << " " << y << endl;
    } 
    ~IndiaBix()
    { } 
};
int main()
{
    IndiaBix objBix; 
    objBix.Display(); 
    return 0;
}
Constructor
Destructor
Default Destructor
Function Template
Answer: Option
Explanation:
No answer description is available. Let's discuss.
Discussion:
1 comments Page 1 of 1.

Subhodeep said:   8 years ago
Anything that has a ~ before a any declared constructor name, it is called a destructor.

Please correct me if I am wrong.

Post your comments here:

Your comments will be displayed after verification.