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.
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.