How can we main a Class as base class,i.e not inherited
further?{please Dont tell using Sealed class,any other way}

Answer Posted / palash

Very Simple....
Create one private Constructor inside the class then we are
not create any object of that class.

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between an application domain and a process?

483


How many types of constructors are available in c#?

540


Is arraylist type safe in c#?

507


Is string nullable in c#?

455


Different between method overriding and method overloading?

488






What is default value of enum c#?

462


Between windows authentication and sql server authentication, which one is trusted and which one is untrusted?

488


Why do we use namespace in c#?

523


What is the difference between interface and functional interface?

493


What is the difference between public, static, and void?

481


When would you use generics in your code c#?

492


Why do we need to call CG.SupressFinalize?

556


Define assert() method? How does it work?

629


What is exe in c#?

498


Is cli same as the clr?

520