Differeance between Interface and Abstract Class
Interface:
1) Define a Contract.
2) can inherit only interfaces.
3) don't have constructor and distructor.
4) don't have concrete methods.
5) Inheritable by Structure.
6) Multiple inheritance is possible using Interface.
7) All members are Public by default.
Abstract Class:
1) Can't be initiated, partially implemented.
2) Can inherit classes & Interfaces.
3) Can have Constructor & Distructor.
4) Some methods can be concrete.
5) Not inheritable by structure.
6) Multiple inheritance not possible.
7) Members can have many modifiers.
Comments
Post a Comment