VMWare Inc Interview Question
Java DevelopersCountry: United States
Interview Type: Phone Interview
There are 2 types of Exception in Java:
1) Checked
2) UnChecked
1) Checked exception are those exceptions which you have to catch At compile time, when you compile your java programe your compiler check for checked exceptions in your program if it occurs it gives you Exception Stack. Eg, IOException, FileNotFoundException etc.
Note: All Exceptions are Checked except RunTimeException and its sub classes.
Java has checked and unchecked exceptions.
- Subhajit June 05, 2013Checked exceptions are those which are checked at compile time.
The designers of java believe that the program can recover from checked exceptions eg: IOException, FileNotFoundException.
The unchecked exceptions are those that occur at run time.
It is not possible to recover from unchecked exceptions like RunTimeExceptions, NullPointerExceptions.