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


Can you allow class to be inherited, but prevent the method
from being over-ridden?

Answers were Sorted based on User's Feedback



Can you allow class to be inherited, but prevent the method from being over-ridden?..

Answer / umesh

Yes, just leave the class public and make the method sealed.

Is This Answer Correct ?    17 Yes 1 No

Can you allow class to be inherited, but prevent the method from being over-ridden?..

Answer / anubhav gupta

We can use shadowing concept.
For shadowing use New keyword in derived class method.
Through this we can prevent the method from being over
ridden.

Is This Answer Correct ?    6 Yes 3 No

Post New Answer

More C Sharp Interview Questions

What is data type c#?

0 Answers  


What are the Types of optimization and name a few and how do u do?

0 Answers   BirlaSoft,


What are Memory foot print of an exe?

0 Answers   MCN Solutions,


Explain About CLS?

0 Answers   Microsoft,


What is the difference between decimal and integer?

0 Answers  


What is system console writeline in c#?

0 Answers  


What can be done with c#?

0 Answers  


What is uint64_t?

0 Answers  


Can an interface inherit an interface

1 Answers   Synechron,


Distinguish between system.string and system.text.stringbuilder classes?

0 Answers  


Define encapsulation?

0 Answers   Siebel,


Why do we use 0?

0 Answers  


Categories