4 AnswersNew Answer
https://www.sololearn.com/learn/Java/2175/?ref=app Exception handling is extremely important when runtime error occurs in a program
If exceptions are not handled, the whole program will crash. Good exception handling makes sure the program keeps running even though errors are encountered as there is always a backup plan in that case.
so to program wont stop when an exception occures
Exception Handling in Java is a very interesting topic. Exception is an error event that can happen during the execution of a program and disrupts its normal flow. Java provides a robust and object oriented way to handle exception scenarios, known as Java Exception Handling . We will look into following topics in this tutorial. An exception can occur for many different reasons. Following are some scenarios where an exception occurs. A user has entered an invalid data. A file that needs to be opened cannot be found. A network connection has been lost in the middle of communications or the JVM has run out of memory. Read more:- http://crbtech.in/Java-Training/exception-handling-java/