EXCEPTIONS AND I/O STREAMS

Exception is an occurrence of an undesirable situation that can be detected during program execution.  Division by zero is an exception.  Other exceptions are opening a nonexistent file or an out of bounds array.  A code to handle exceptions will ensure that the program does not terminate.  The code to handle exceptions depends on the type of application developed.  Exception-handling is provided by adding code at the point where an error might occur.  This allows the programmer reading the code to see the exception-handling and the regular code to determine if the error-checking code is properly implemented.   However, the program can become cluttered making it more difficult to understand.

The class Throwable, which is derived from the class Object, is the superclas of teh class Exception.