What is the difference between inherited methods and public methods?

122 Views Asked by At

I have trouble understanding how an inherited method in a subclass from a superclass differs from a public method in a class which can be used in another class.

1

There are 1 best solutions below

0
Datta Diware On BEST ANSWER

Please go through the basic OOP concepts, you will understand the difference. Very short answer could be that public methods you can just access where as using inheritance subclasses can modify existing behaviour.