Question: What will code output? abstract class P { public abstract int calculate ( int x ) ; } class Q extends P { public int
What will code output? abstract class P
public abstract int calculateint x;
class Q extends P
public int calculateint x
return x ;
class R extends Q
public int calculateint x
return super.calculatex;
public class Test
public static void mainString args
P obj new R;
System.out.printlnobjcalculate;
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
