Object Oriented Programming (OOPs)

© examsiri.com
Question : 32 of 72
 
Marks: +1, -0
Given:
1.public class SuperCalc {
2.  protected static int multiply(int a, int b) { return a * b;}
3.}
and:
4.public class SubCalc extends SuperCalc{
5.  public static int multiply(int a, int b) {
6.   int c = super.multiply(a, b);
7.   return c;
8.  }
9.}
and:
10.SubCalc sc = new SubCalc ();
11.System.out.println(sc.multiply(3,4));
12.System.out.println(SubCalc.multiply(2,2));

What is the result?
Go to Question: