What is the basically use of finally while we know it
is always executed but why?
Answer Posted / sivadasan
Finally block always execute, its not consider whether an
exception is raised or not. Once try block is executed
means finally will be executed.
Finally block is necessary, often sufficient to execute
some important things its nothing but connection close
stmt..
system.exit(0); given in try catch block means finally
block will not be executed.
Is This Answer Correct ? | 4 Yes | 0 No |
Post New Answer View All Answers
How does linkedlist work in java?
What does those terms actually mean included in the j.d.k i.6?
What is api in java?
Why java is used everywhere?
What programs use java?
What is arrays aslist in java?
what is the purpose of using rmisecuritymanager in rmi?
What are the features in java?
Can we sort arraylist in java?
Why can't we use static class instead of singleton?
What is json parser in java?
Can we create an object if a class doesn't have any constructor ( not even the default provided by constructor ) ?
What is a class component?
How would you dynamically allocate memory to an array?
What is the epoch date?