why use interface? if interface declear a method implement
in class. why direct implement method in class



why use interface? if interface declear a method implement in class. why direct implement method in..

Answer / fajruddin sk

interface mainly use as of my knowledge-----> (1) for loosely coupling(2)just declare a rule(3)for giving a special behavior(Marker interface) (4)for multiple inheritance

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Core Java Interview Questions

What is difference between == equals () and compareto () method?

0 Answers  


What is a final class ?

0 Answers  


Define nashorn in java8.

0 Answers  


What is the difference between this() and super() in java?

0 Answers  


What is the difference between array and arraylist? what is the difference between arraylist and linkedlist?

8 Answers   EDS, Matrix,






posted in online test

1 Answers  


diff between abstract methods and interfaces with programing (code) example?

2 Answers  


Is it safe for adding 10,00,000 records/objects to HashMap?, i.e is it safe to add millions of objects to HashMap?

2 Answers  


What is string array?

0 Answers  


How can you read an integer value from the keyword when the application is runtime in java? example?

0 Answers   HCL,


What is a boolean used for?

0 Answers  


How many types of keywords are there?

0 Answers  


Categories