Question: Given the following declarations Super1 objSuper1 = new Super1(); Sub1 objSub1 = new Sub1(); Question: True or False - assuming that Sub1 extended Super1 (i.e.
Given the following declarations Super1 objSuper1 = new Super1(); Sub1 objSub1 = new Sub1(); Question: True or False - assuming that Sub1 extended Super1 (i.e. Super1 is the superclass for Sub1), can objSub1 be typecasted to Super1 without error?
True | ||
False |
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
