Question 4


The following code will give 1: class Test 2: { 3: static void show() 4: { 5: System.out.println("Static method in Test"); 6: } 7: } 8: public class Q4 extends Test 9: { 10: void show() 11: { 12: System.out.println("Overridden static method in Q4"); 13: } 14: public static void main(String[] args) 15: { 16: } 17: } A) Compilation error at line 3. B) Compilation error at line 10. C) No compilation error, but runtime exception at line 3. D) No compilation error, but runtime exception at line 10.