Thursday, 20 July 2017

class using constructor

#include<iostream.h>
#include<conio.h>
class A
{
public:
A()
{
cout<<"this is construtor\n";
}
~A()
{
cout<<"this is dest...\n";
}
};
void main()
{
clrscr();
A obj;
getch();
}

No comments:

Post a Comment