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...

How would you stop a class from class from being derived or
inherited?The constructer should not be Private,as object
instantiation should be allowed.

Answer Posted / boriska

make destructor private. Derived class would not be able to
access it, and compiler will produce error, when instance of
derived class is deallocated.

Is This Answer Correct ?    3 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Comment on c++ standard exceptions?

1075


What is anonymous object in c++?

1101


What does the following do: for(;;) ; a) Illegal b) Loops forever c) Ignored by compiler...not illegal

1179


What is the difference between delegation and implemented-in-terms-of?

1007


Does c++ support exception handling?

1067


What is a constructor and how is it called?

1050


What is a node class in c++?

1073


an operation between an integer and real always yeilds a) integer result b) real result c) float result

1156


What is the difference between #define debug 0 and #undef debug?

1190


What is the use of volatile variable?

1088


What is std :: flush?

1076


Why #include is used?

1071


What do you understand by a pure virtual member function?

1009


What is dynamic and static typing?

1192


What is runtime polymorphism in c++?

1162