what can you do with an exception once youve


What can you do with an exception once you've caught it?

1. Fix the difficulty and try again.
2. Do anything else instead.
3. Exit the application along with System.exit()
4. Rethrow the exception.
5. Throw a latest exception.
6. Return a default value (in a non-void method).
7. Eat the exception and return from the techniques (in a void method).
8. Eat the exception and continue in the similar method (Rare and dangerous. Be extremely careful if you do this. Novices almost always do this for the wrong reasons. Do not simply to prevent dealing with the exception. Commonly you should only do this if you can logically guarantee in which the exception will never be thrown or if the statements inside the try block do not required to be executed correctly in order for the next code to run.)

Printing an error message through itself is generally not an acceptable response to an exception.

Request for Solution File

Ask an Expert for Answer!!
JAVA Programming: what can you do with an exception once youve
Reference No:- TGS0284886

Expected delivery within 24 Hours