Java - Static Keyword
Consider this code:
What will be the output?
class A {
static int x = 5;
}
class B extends A {
static int x = 10;
}
public class Test {
public static void main(String[] args) {
System.out.println(A.x);
System.out.println(B.x);
}
}What will be the output?
