Page 1 of 1

What will the variable "y" be in class B?class A {int x;protected:int y;public:int age;};class B : private A {string nam

Posted: Wed Aug 03, 2022 9:20 am
by answerhappygod
What will the variable "y" be in class B?class A {int x;protected:int y;public:int age;};class B : private A {string name;public:void Print() {cout << name << age;}};

A. public
B. private
C. protected
D. None of these