Select the correct option to test your answer:
Computer
Overriding And Overloading
Difficulty: Medium
What will be the output? class A{ static void method(){ System.out.println("Class A method"); } } class B extends A{ static void method(){ System.out.println("Class B method"); } } public class Test{ public static void main(String args[]){ A a = new B(); a.method(); } }
More Computer Questions
Which of these methods can be used to obtain the reference to the container that generated a ContainerEvent?
What is the result of 8 - 6 / 2 ?
What is the output of the following code: class MyClass: count = 0 def init(self): MyClass.count += 1 obj1 = MyClass() obj2 = MyClass() print(obj1.count)
Which application allows a user to access and change remote files without actual transfer?
Which of the following selector is used to selects the element that is the root of the document?