MENU
Question -

Answer the question (i) to (iv) based on the following :

class Interior
{
int OrderId; 
char Address[20]; 
protected:
float Advance; 
public:
Interior();
void Book(); 
void View();
};
class Painting : public Interior
int WallArea, ColorCode; 
protected:
char Type; 
public:
Painting(); 
void PBook(); 
void PView();
};
class Billing : public Painting
{
float Charges; 
void Calculate(); 
public:
Billing(); 
void Bill();
void BillPrint();
};
(i) Which type of Inheritance of the following is illustrated in the above example ?
— Single Level Inheritance 
— Multi Level Inheritance 
— Multiple Inheritance



Answer -

Mutli Level Inheritance
(ii)    Write the names of all the data members, which are directly accessible from the member functions of class painting.
Wall Area, Color Code, Type, Advance
Note :
•    No marks to be awaarded for any partial or additional answer(s)
(iii)    Write the names of all the member functions, which are directly accessible from an object of class Billing. Bill(), BillPrint(), PBook(), PViewQ, Book(), View()
Note : No marks to be awarded for any partial/ additional answer(s)
• Constructors can be ignored

Comment(S)

Show all Coment

Leave a Comment

Free - Previous Years Question Papers
Any questions? Ask us!
×