Vidyalelo
Java Programming · Q97

Constructors and Methods

Programming · Java Programming · question 97

Q97

What will be the output of the following Java code? class A A()throws IOException class B extends A B() public static void main(String[]args)

A.
compile time error
Answer
B.
run time error
C.
compile and runs fine
D.
unreported exception java.io.IOException in default constructor

Answer: Option A

Solution

Answer: Option A
No explanation is given for this question Let's Discuss on Board