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


Please Help Members By Posting Answers For Below Questions

What modifiers may be used with an inner class that is a member of an outer class in java programming?

525


Is a char always 1 byte?

496


Can we execute a program without main?

528


What is the difference between static method and instance method in Java?

560


What are the 8 primitive data types in java?

540






What is java string pool?

535


What is canonical name in java?

613


How do I convert a numeric ip address like 192.18.97.39 into a hostname like java.sun.com?

597


Explain with example the concept of constant variable in java.

616


What are the limitations of procedural programming approach?

521


Can this keyword be used to refer static members?

540


What is the difference between hashmap and hashtable in java?

550


Explain the different forms of polymorphism?

559


What is a singleton puppy?

520


What are the differences between graph and tree?

641