I have a class which is abstract which contains only the
abstract methods. This is similar to an interface. Then, if
i have given a choice to choose one of them. Which one i
have to choose and why?
Answer Posted / madhav
Interface is preferable to Abstract class as when ever in
instance is created for subclasses of this,constructors
will be called hirarchially consuming some time for each
constructor call..
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
I want to re-reach and use an object once it has been garbage collected. Define how it’s possible?
Why Java is not pure Object Oriented language?
What is integer valueof?
Can we use return in constructor?
What is run time allocation?
What is the difference between static and global variables and also define what are volatile variables?
Can an interface have a class?
What is the difference between import java.util.date and java .util?
What is java and their uses?
Difference between final and effectively final ? Why is effectively final even required ?
How to handle a web browser resize operation?
Is java se open source?
how we can make a write-only class in java?
Given a singly linked list, determine whether it contains a loop or not without using temporary space?
What are pass by reference and pass by value?