Select the correct option to test your answer:
Computer
Inheritence
Difficulty: Medium
What is the result of the following code snippet? class Parent { private int x = 10; } class Child extends Parent { int x = 20; void display() { System.out.println(super.x + " " + x); } } public class Main { public static void main(String[] args) { Child obj = new Child(); obj.display(); } }
More Computer Questions
The C library function . . . . . . . . breaks string s1 into a series of tokens using the delimiter s2.
Which is a fast C++ based JavaScript interpreter?
In help menu of Excel, which of the following tabs are found?
A character that represents one or more unknown character is
The statement that constructs a branching flow-control construct is . . . . . . . .