Question: 1 : #include 2 : using namespace std; 3 : 4 : / / 5 : 6 : class A 7 : { 8 :
: #include :
using namespace std;:
:
:
: class A
:
: private:
: int x;
: protected:
: int getX;
: public:
: void setX;
: ;
:
: int A::getX
:
: return x;
:
:
: void A::setX
:
: x;
:
:
:
: class B
:
: private:
: int y;
: protected:
: A objA;
: int getY;
: public:
: void setY;
: ;
:
: void B::setY
:
: y;
: int a objA.getX; :
:
:
:
: class C: publicA
:
: protected:
: int z;
: public:
: int getZ;
: void setZ;
: ;
:
: int C::getZ
:
: return z;
:
:
: void C::setZ
:
: z;
:
Class C has public inheritance with the class A Identify and list class Cs
private, protected and public member variables resulting from the
inheritance.
aThis question is based on question d in the written Assignment Question included a code fragment that you had to answer questions on In this code fragment class C has public inheritance with the class A Identify and list class Cs public data members resulting from the inheritance.
Class C has no public data members resulting from the inheritance.
Select one:
True
False
bThis question is based on question d in the written Assignment Question included a code fragment that you had to answer questions on In this code fragment class C has public inheritance with the class A Identify and list class Cs protected data members resulting from the inheritance.
Class C has no protected data members resulting from the inheritance.
Select one:
True
False
cThis question is based on question d in the written Assignment Question included a code fragment that you had to answer questions on In this code fragment class C has public inheritance with the class A Identify and list class Cs private data members resulting from the inheritance.
Class C has no private data members or member functions resulting from the inheritance because private data members are never inherited.
Select one:
True
False
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
