Difference between abstract class and Interfaces?
Answer Posted / ranganathkini
An Interfaces defines a public contract of methods for the
classes that implement it. An implementing class must
implement all the method defined by the interface.
An abstract class on the other hand not only defines a
public contract of methods but may also provide partial
implementation of some or all of the class methods. A
subclass of an abstract class inherits the partial
implementation (if any) or must provide a concrete
implementation of the abstract methods.
| Is This Answer Correct ? | 4 Yes | 0 No |
Post New Answer View All Answers
What are the methods of object class ?
Describe what happens when an object is created in java ?
What is functional interface in javatpoint?
What are triggers in DB? Explain their types. How do they work?
What is try-with-resources in java?
What is the size of a string in java?
Tell us something about an iterator.
What is meant by distributed application? Why are we using that in our application?
Explain the usage of this with constructors?
What is substring 1 in java?
What is indexof in java?
What is the impact of declaring a method as final?
Is it possible to use Semaphore/ Mutex in an Interrupt Handler?
What is Recursion Function?
Can we assign null to double in java?