What is the difference between Abstract and Interface?
Answer Posted / muhammad hussain wazir pakista
1: Abstract class contains abstract and non abstract methods
while interface contains all abstract methods.
2: Interface only contain definition of method no
implementation but Abstract class can have this quality.
3: We can not create object of abstract class.
4: We can create constructor and Destructure Abstract class
can while this can be do in Interface.
5: In interface all methods are abstract and have no keyword
of Abstract with method.
| Is This Answer Correct ? | 5 Yes | 2 No |
Post New Answer View All Answers
Overloaded constructor will call default constructor internally?
How do you achieve polymorphism in c#?
What is a singleton unity?
What is static noise?
What is thread in c#?
What are the string functions in c#?
What is exe file in c#?
What is default c#?
What is lazy loading entity framework?
What is an inheritance ?Give an example in which inheritance is used?
can you declare an override method to be static if the original method is not static?
Which sorting algorithm is best?
Why use a singleton instead of static methods?
What is the benefit of dependency injection c#?
What does console readline do?