Question: 20. What is the output of this program? import java.io.IOException; public class Derived { public void getDetails() throws IOException { System.out.println(Derived class); w public class
20. What is the output of this program? import java.io.IOException; public class Derived { public void getDetails() throws IOException { System.out.println("Derived class"); w public class Test extends Derived { public void getDetails() throws Exception { System.out.println("Test class"); public static void main(String[] args) throws IOException { Derived obj = new Test(); obj.getDetails(); A. Compilation error due to line 23 B. Compilation error due to line 24 C. Compilation error due to line 25 D. All the above
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
