Respuesta :

Answer:

The correct answer for the following question is "interface" .

Explanation:

Interface is used for achieving the multiple inheritence in java.Interface is kind of abstract class which contain abstract method.When we use implement method it indicate the use of interfaces.

Following are the example of class that uses interface .

Following are the code in java

interface a // creating interface

{  

 public void fun1(); // interface method (does not have a body)

}  

class abc implements a

{

 public void fun1()

{

   System.out.println("hello brainly");

 }

}

class Main //main class

{

 public static void main(String[] args) // main method

{

   abc ob=new abc(); // creating object

   ob.fun1();  // calling fun1() function

 }

}

In this we create an interface a which have abstract method fun1()(only declaration) the class abc implements the interface " a" and define the method fun1() .On creating the object of class abc it call fun1() i.e it print  hello brainly

output:hello brainly