What is meant by final class, methods and variables?
Answers were Sorted based on User's Feedback
when you declare a class as final, that class cannot be
extended.In java "String" class is final.
when you declare the variable as final then we can
intialize it only once.it is constant.
when declare the method as final we cannot override the
method
| Is This Answer Correct ? | 12 Yes | 0 No |
Answer / ravikiran(aptech mumbai)
final class:Is the one which cann't be subclassed
final method:Is the one which cann't be overrided
final variable:is the one which acts like a constant
| Is This Answer Correct ? | 12 Yes | 1 No |
Answer / suresh chand
final class: we can't inherit that class
final method: we can't override that method
final variable: we can't change the value of that var.
| Is This Answer Correct ? | 9 Yes | 0 No |
Do you know why doesn't the java library use a randomized version of quicksort?
Why is the singleton pattern considered to be an anti pattern?
what do you understand by synchronization? : Java thread
What is the destroy method?
Why convert an applet to an application?
Explain about public and private access specifiers?
Can an abstract class be final?
different types of threads?
What do you understand by looping in java? Explain the different types of loops.
Is array an object in java?
What is a container in a gui?
Which is easier .net or java?