Search Interview Questions | ![]() ![]() Click here and help us by providing the answer. ![]() Click Correct / Improve and please let us know. |
|
| ||||
Core Java - Interview Questions and Answers for 'Final method' - 4 question(s) found - Order By Newest | ||||
![]() | ||||
| ||||
Ans. Its a method which cannot be overridden. Compiler throws an error if we try to override a method which has been declared final in the parent class. | ||||
![]() | ||||
![]() ![]() ![]() ![]() ![]() ![]() | ||||
![]() | ||||
| ||||
Ans. No. compareTo method is declared final for the Enumerations and hence cannot be overriden. This has been intentionally done so that one cannot temper with the sorting order on the Enumeration which is the order in which Enum constants are declared. | ||||
![]() | ||||
![]() ![]() ![]() ![]() | ||||
| ||||
Ans. A Method that cannot be overriden in the sub class. | ||||
![]() | ||||
![]() ![]() ![]() ![]() ![]() | ||||
![]() | ||||
| ||||
Ans. Yes. As they cannot be overridden , there is no use of virtual table concept which is used for dynamic binding resolution. | ||||
![]() | ||||
![]() ![]() ![]() ![]() | ||||