Can a java abstract class method be final and abstract both?

Answer: No, an abstract class method cannot be final and abstract both in java e.g.

 

 

Reason is that, by making a method final in abstract class, we are stopping derived class not to override and implement it. Whereas, by making it abstract, we are forcing derived class to override it and implement it. So, making a method both final and abstract is contradictory. Hence, using both final and abstract method does not make any sense.
Secondly, final method must have a body whereas abstract method can have only declaration. So, it is also contradictory.

 

 

If we use both final and abstract before method, then compiler will flash a compile time errors.

Read More