When we will use an Interface and Abstract class?

Answer Posted / abc

interface is used when we want all the methods implement
the methods differnetly in different situations.


Abstract class
We also use abstract classes to override the
abstract methods that it contains.Otherwise the child class
will mentioned as abstract.

Is This Answer Correct ?    6 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How many ways can we create singleton class?

496


Does every java program need a main?

530


When the constructor of a class is invoked?

581


What is super keyword explain with example?

525


What is use of static method?

528






What are sets in java?

500


Why convert an applet to an application?

610


Can we use catch statement for checked exceptions?

507


What is slash r?

533


How do you reverse a word in java?

524


how to convert Java project into Maven ?

577


State one difference between a template class and class template.

614


What are the benefits of operations in java?

488


Can substring create new object?

553


What is the generic class?

524