Vidyalelo
Java Programming · Q115

Interfaces and Abstract Classes

Programming · Java Programming · question 115

Q115

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(b.equals(a));

A.
0
B.
1
C.
true
D.
false
Answer

Answer: Option D

Solution

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