officiallyDylan1338 officiallyDylan1338
  • 19-07-2019
  • Computers and Technology
contestada

Which technique/concept can be use toimplement multiple inheritances
in java?

Respuesta :

tardymanchester tardymanchester
  • 24-07-2019

Answer:

Interface

Explanation:

Java does not supports multiple inheritance by class, but we can implement multiple inharitacnce in  java using interface, with interface we uses implements keyword.

Example-

Declare interface like below code -

interface parent{

}

and use in child class like below code -

class Child1 implements interface{

}

class Child2 implements interface{

}

Answer Link

Otras preguntas

Calculate the number of moles 9.00 g of H2O 88.0 g of CO2 1.70 g of NH3
What percent of 1270 is 375?
One positive number is 5 times another number. The difference between the two numbers is 200, find the numbers.
What would happen if our Eyes were unable to control the amount of light that enteres them?
How is the behavior of waves affected by a medium?
49.5 is what percent of 33?
Describe the policy of appeasement and it emboldened Hitler leading up to World War II
Jessica is making 2 loaves of banana bread. She needs 3/4 cup of sugar for each loaf. Her measuring cup can only hold 1/4 cup of sugar. How many times will Jess
Evaluate log (base 9) 27. Can someone explain this one for me so i could do some tasks on my own?
Describe the policy of appeasement and it emboldened Hitler leading up to World War II