Exception Handling




Fault access during the compiletince of program is known as error there are two type of error as given below :-

  1. physical error :-

Error access during the compiletince time of program due to wrong syntax is known as physical error as syntax error.

  1. Logical error:-

If the out put obtained form the program is not match with the accepted out put then such type of error is known logical error.


            Abnormal condition occurs during the runtime of program is known as exception.

During the run time of program if any exception is found then execution control will stop the execution of next and terminate the complete process of program to stop the termination of the program it is necessary to handle the exception by using try catch statement.

Generalized Exception

It is a concept of Java language in which exception class handles any type of exception.

Exception is a standard in built class available in Java language it is the super class of all the exception classes all the object of subclass can dispatch their data to the object of exception class by using the concept of dynamic method dispatch.

Example :-

            Class my exception 1


Public static void main (string argument+[ ])




Integer a=10, b=0, e;


System out printin (“value=” +C);


Catch (exception e)

Leave a Reply

Your email address will not be published. Required fields are marked *