Question: Please help me code the following in JAVA TestExceptions class: 1. Simple exception handling a. Download the following file from the class website: TestExceptions.java b.
Please help me code the following in JAVA

TestExceptions class: 
1. Simple exception handling a. Download the following file from the class website: TestExceptions.java b. Compile the code and notice the compilation error message. c. Modify the main0 method to propagate the IOException (this is an ancestor of FileNotFoundException). This is done using a throws clause when the method is first declared. While there are multiple exceptions that might be thrown by this code, this change should propagate all of them, since they all inherit from IOException Execute the program and notice the run-time error. Modify the code to handle the exceptions using a try-catch block instead of propagating the exception. When the exception occurs print: "The file you have requested cannot be found. Test your changes. d. e. f. g
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
