Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

class professor {};
class teacher : public virtual professor {};
class researcher : public virtual professor {};
class myprofessor : public teacher, public researcher {};

Referring to the sample code above, if an object of class
"myprofessor" were created, how many instances of professor
will it contain?
a) 0
b) 1
c) 2
d) 3
e) 4

Answer Posted / d.sakthi

ans is 1 option b
reason:as three classes are derived from base class single instance is enough

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the use of 'using' declaration in c++?

1141


How do I run a program in notepad ++?

1115


What are references in c++?

1142


Can I learn c++ in a week?

1078


What is the difference between a baller and a reference in C++?

1126


What is main function in c++ with example?

1230


What is vectorial capacity?

1168


What are stacks?

1067


How can you link a c program with a c function?

1076


What is using namespace std in c++?

1165


What is the use of bit fields in structure declaration?

987


What is #include iostream h in c++?

1165


Define a constructor - what it is and how it might be called (2 methods)?

1145


Do you know the use of vtable?

1136


When is the copy constructor called?

1148