Question: java An advantage of inheritance is that: 1.All methods, both public and private, can be inherited. 2.All instance variables can be uniformly accessed by subclasses
java
An advantage of inheritance is that:
| 1.All methods, both public and private, can be inherited. | ||
| 2.All instance variables can be uniformly accessed by subclasses and superclasses. | ||
| 3.Objects of a subclass can be treated like objects of their superclass. | ||
| 4.None of these. |
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
