1.

What will be the out of the following program?

#include<iostream.h> class BixBase
{ public: int x, y; public: BixBase(int xx = 0, int yy = 0) { x = xx; y = yy; } };
class BixDerived : public BixBase
{ private: BixBase objBase; public: BixDerived(int xx, int yy) : BixBase(xx), objBase(yy) { cout << x << " " << this->x << " " << BixBase::x << " " << this->objBase.x ; } ~BixDerived() { }
};
int main()
{ BixDerived objDev(11, 22); return 0;
}

A. 11 22 0 0
B. 11 11 0 22
C. 11 11 11 0
D. 11 11 11 22
E. The program will report compile time error.
Answer» E. The program will report compile time error.


Discussion

No Comment Found

Related MCQs