Lets say I have a class called Person
.
Then I make a child class called Adult
(so an adult would extend Person
)
Lastly, I make a child class of the Adult
class called Teacher
(so the Teacher
would extend Adult
)
If there was a toString
method (@Override
) for Person
class, does all the child class (Teacher
and Adult
) have to have a toString
method?
And if there is a toString
method specific to Person
and another toString
specific to Adult
class, how can I reference the toString
method from the Teacher
class from the Adult
class using super
reference? (all toString
s are overridden)