{ public :
A(void)
{cout << "Howzaht" ; }
~ A(void)
{cout << "whatizit " ; }
};
class B:A
{ public:
~ B (void)
{
cout << "WYSIWYG" ;
}
cout << "YACC" ;
}
};
The declaration B x;
{ public :
A(void)
{cout << "Howzaht" ; }
~ A(void)
{cout << "whatizit " ; }
};
class B:A
{ public:
~ B (void)
{
cout << "WYSIWYG" ;
}
cout << "YACC" ;
}
};
If the main function has the two statements
B x ;
cout << " done" ;
the output will be