Step by step learning
What is the result of the code:
interface MyInterface { int test(int i); } class Test { public static void main(String[] args) { int i = 0; MyInterface x = i -> i * 8; System.out.println(x.test(2)); } }
c. Compilation error
The output is "16"
The output is "0"
Please log in or register to have a possibility to add comment.
Please log in or register to have a possibility to add comment.