what is main purpose of interface?

Answers were Sorted based on User's Feedback



what is main purpose of interface?..

Answer / saikatk

There is no multiple inheritance in java,we can't extends
more than one class at a time,so interface is a way to
implement multiple inheritance in java, and from design
point view when we have some class specific behaviours we
can put interface as a base of the classes.

Is This Answer Correct ?    44 Yes 4 No

what is main purpose of interface?..

Answer / javachi

The purpose of interface is to create the relationship between the parties involved. parties is nothing but a set of classes relates with each other. this is required when the sub class inherits the property of two or more superclasses(multiple inheritance)

Is This Answer Correct ?    7 Yes 8 No

Post New Answer

More Core Java Interview Questions

How many types of memory areas are allocated by jvm?

0 Answers  


What is array pointers ?

0 Answers   Amdocs,


why is S capital in System.out.println ????

6 Answers  


Why destructor is not used in java?

0 Answers  


Can constructor return value?

0 Answers  






What is use of map in java?

0 Answers  


What is prime number in java?

0 Answers  


How do you join strings in java?

0 Answers  


List the interfaces which extends collection interface?

0 Answers  


What is a priority queue java?

0 Answers  


Explain the term virtual machine?

0 Answers   Adobe,


Can extern variables be initialized?

0 Answers  


Categories