Checked and UnChecked Exception
Checked Exceptions:
The Exception which are checked by compiler for smooth execution of the program at runtime are called checked ExceptionIn the case of checked exceptions compiler will check whether we are handling exception if the programmer not handling then we will get compile time error
Example:HallticketMissingExceptopn
FileNotFoundExceptiom
PenNotWorkingException
Unchecked Exceptions:
The Exception which are not checked by compiler are called unchecked exception
Example: ArithmeticException
BombBlastException
NullpointerException
*Wheather exception is Checked or Unchecked compulsory it will occur only at Runtime.There is no chance of pccuring any exception at compile time .Runtime exception and its child classes,error and its child classes are unchecked except this remaining are checked exceptions
No Comments Yet!!