If all the methods in abstract class are declared as
abstract then what is difference between abstract class and
in interface?
Answer Posted / namita
In abstract class concrete methods are also there. concrete
methods are the one which has implementation. so in future
if any programmer wants to give concrete methods can use
abstract class not interface.
In abstract class for methods and variables
public,private,protected modifier can be use. but in
interface public and abstract are permitted.
Is This Answer Correct ? | 18 Yes | 6 No |
Post New Answer View All Answers
What is meant by main method?
What is the purpose of checked and unchecked exceptions in JAVA?
What is java and why do we need it? Explain
What does index mean in java?
how can you catch multiple exceptions in java?
What is Classloader in Java?
How do you execute a thread in java?
Are private methods final?
How destructors are defined in java?
What does system.gc() and runtime.gc() methods do?
What is default exception handling in java?
Is java a compiler?
What is use of inner class in java?
How does hashmap work in java ?
Difference between notify() method and notifyall() method in java?