How prevent method being overridden

How prevent method being overridden

Answer : To prevent a method from being overridden use “final” keyword directly precede your method name. Using “final” keyword ┬ájava ensure that, method cannot be overridden by any of tis child class.

Leave a Reply

Your email address will not be published. Required fields are marked *