Java - Exceptions - Interview Questions and Answers on FileNotFoundException

Q1.  Which exceptions should be handled with the following code ?

FileOutputStream fileOutputStream = new FileOutputStream(new File("newFile.txt"));

Ans. FileNotFoundException

Q2. Which interfaces are implemented by FileNotFoundException?

Ans.[Serializable]

Q3. Which is the Parent Class of FileNotFoundException class?

Ans.IOException

Q4. What is the package name for FileNotFoundException class?

Ans.java.io