Q182
What will be the output of the following Java program? class X int a; double b; class Y extends X int c; class Output public static void main(String args[]) X a = new X(); Y b = new Y(); Class obj; obj = b.getClass(); System.out.print(obj.getSuperclass());
A.
X
B.
Y
C.
class X
AnswerD.
class Y
Answer: Option C
Solution
Answer: Option C
No explanation is given for this question Let's Discuss on Board