Difference between abstract class and interface
Answer Posted / mkm
)1. Accessibility modifier(Public/Private/internal) is
allowed for abstract class.
Interface doesn't allow accessibility modifier
2. class can inherit only one abstract class
class can implement more than one interface.
(2) An abstract class can contain fields,
constructors, or destructors and implement properties. An
interface can not contain fields, constructors, or
destructors and it has only the property's signature but no
implementation.
(3) An abstract class cannot support multiple
inheritance, but an interface can support multiple
inheritance. Thus a class may inherit several interfaces
but only one abstract class.
• Interface is used to "implements"; whereas abstract class
is used to "extends".
• Interface can be used to achieve multiple inheritance;
abstract class can be used as a single inheritance.
Is This Answer Correct ? | 13 Yes | 2 No |
Post New Answer View All Answers
What is application session?
How can I configure asp.net applications that are running on a remote machine?
What is manifest in .net framework?
How will you do Redo and Undo in a TextControl?
What is a global postback url?
What is autopostback in dropdownlist in asp net?
What is asp.net version?
How do you design a website with multilingual support in ASP.NET ?
Describe the Server Control Events of ASP.NET?
What is difference between session and cookies in asp net?
can any one find and tell the difference between dot net and php which one is best ? which one we get more salary? which one is stable and which one is best for freshers and also better in future and carrer ? which one we wil get more salary sir ? please send ur valuable suggestions to kiranpulsar2007@gmail.com
What type of code, client-side or server-side, is found in a code-behind file of a Web page?
They mostly asked difference between versions of technologies
What is http only cookie?
What is ascx?