What is the use of finally

Showing Answers 1 - 1 of 1 Answers

vinod_arya

  • Oct 2nd, 2005
 

it is the block which is executed in both the case, whether exception is generated or not

ex:

class test

{

void disp()

{

try

{}

catch(Exception e)

{}

finally

{

system.out.println("Finally");

}

}

}

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions