EXCEPTION HANDLING IN JAVA
Why do we use exception handling?
Exception handling is highly recommended to handle exceptions and
the main objective of exception handling is graceful termination of the
program.
try
{
//read data from remote file locating at USA
}
catch(fileNotFoundException e)
{
//use local file & continue rest of the program normally
}
{
//read data from remote file locating at USA
}
catch(fileNotFoundException e)
{
//use local file & continue rest of the program normally
}