Java - Interfaces
Consider this code:
What is the output?
interface X {
default void show() { System.out.println("X show"); }
}
interface Y {
default void show() { System.out.println("Y show"); }
}
class Z implements X, Y {
public void show() {
X.super.show();
Y.super.show();
}
}
public class Test {
public static void main(String[] args) {
new Z().show();
}
}What is the output?
