what is difference between interface and abstract class..?

Answer Posted / kumar

Interface:
1)It will contain only abstract methods

Abstract Class:
1)Any class can be declared an abstract class ,but if a
class contains an abstract method it should be declared as
an abstract class.

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which class represents the socket that both the client and server use to communicate with each other?

583


Why string is immutable or final in java

640


Why is a string immutable?

552


What is the use of set in java?

622


Explain jdk, jre and jvm?

577






Explain static nested classes ?

605


How to print nodes of a Binary tree?

1764


How do you compare two objects?

534


Write a method that will remove given character from the string?

583


can java object be locked down for exclusive use by a given thread? Or what happens when a thread cannot acquire a lock on an object? : Java thread

548


Why do we need hashmap in java?

572


Does hashset allow duplicates in java?

596


What is the difference between the Reader/Writer class hierarchy and the InputStream/OutputStream class hierarchy?

648


Can you give names of Container classes?

1867


What is rmi and steps involved in developing an rmi object?

579