An advantage of inheritance is that ________. all methods can be inherited all instance variables can be uniformly accessed by subclasses and superclasses objects of a subclass can be treated like objects of their superclass None of these.

Respuesta :

Answer: ....

all instance variables can be uniformly accessed by sub classes and super  classes objects of a subclass can be treated like objects of their super class

Explanation:

Inheritance in Java is a mechanism in which one object acquires all the properties and behaviors of a parent object. The idea behind inheritance in Java is that you can create new classes that are built upon existing classes. When you inherit from an existing class, you can reuse methods and fields of the parent class.

One of the key benefits of inheritance is to minimize the amount of duplicate.

One of the key benefits of inheritance is to minimize the amount of duplicate code in an application by sharing common code among several sub classes.

Inheritance can also make application code more flexible to change because classes that inherit from a common super class can be used interchangeably.