Consider the following class hierarchy:
(B1 and B2 are subclasses of A and C1, C2 are subclasses of B1) Which of the following statements are correct? Assume that objectOfA, objectOfC1, etc. are objects of classes A and C1 respectively.
Select 1 option
A. objectOfC2 instanceof B2 will return true.
B. objectOfC1 instanceof B1 will return true.
C. objectOfA instanceof B1 will return true.
D. C1 c1 = objectOfA; is a valid statement.
E. B1 b1 = objectOfB2; is a valid statement.
Searches whole web. Use the search in the right sidebar to search only within javajee.com!!!