What will be the out of the following program? #include<iostream.h>
class CuriousTabBase
{
protected:
int x, y;
public:
CuriousTabBase(int xx = 0, int yy = 0)
{
x = xx;
y = yy;
}
void Show()
{
cout<< x * this->y << endl;
}
};
class CuriousTabDerived
{
private:
CuriousTabBase objBase;
public:
CuriousTabDerived(int xx, int yy) : objBase(xx, yy)
{
objBase.Show();
}
~CuriousTabDerived()
{ }
};
int main()
{
CuriousTabDerived objDev(10, 20);
return 0;
}
Discussion & Comments