Question: class A is superclass of class B . Method c ( ) is defined in both classes ( overridden ) What happen to the following
class is superclass of class Method is defined in both classes overridden
What happen to the following code?
A obj new B;
Bc;
syntax error, type mismatch for obj
class As version of method c is executed then class Bs version of method c is executed
class As version of method c is executed
class Bs version of method c is executed
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
