0
what is the use of declaring abstarct method without using it in parent class ???
2 ответов
+ 1
can you explain a little bit more
+ 1
You mean declaring a fully abstract method? So that the parent class knows that the method exists.
Suppose you have a parent class ArrayList that you fill with objects of derived classes. You can then call the method that was fully abstract when defining the parent class but that had been defined in the derived classes on each object of the ArrayList, taking advantage of the polymorphism.