Can a class extend abstract class or interface? why
Answer Posted / abhay bhatia
a class can extend an abstract class and can implement an
interface, why is because even though an abstract class
provide default implementation of its methods, we cannot
instantiate an object of the abstract class and therefore
need a class that extends it to use the instance methods of
this abstract class. An interface on the other hand cannot
even have default implementation, therefore it has to be
implemented to be used
Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
What are register variables what are the advantages?
How to split arraylist elements in java?
What is outofmemoryerror in java?
What is the difference between reader/writer and inputstream/output stream?
Is intellij better than eclipse?
What is data structure in java?
What is pass by value?
How many types of voids are there?
How do you decide when to use arraylist and linkedlist?
What if static is removed from main method?
How do you reverse a word in java?
Which collection is sorted in java?
what are three ways in which a thread can enter the waiting state? Or what are different ways in which a thread can enter the waiting state? : Java thread
What is string :: npos?
How many types of equations are there?