Engineering Full Stack Apps with Java and JavaScript
Consider the following code:
public class Varargs{ public void test(){ test1(10, 20); //1 } public void test1(int i, int... j){ System.out.println("1"); } public void test1(int... i ){ System.out.println("2"); } public void test1(int i, int j){ System.out.println("3"); } public static void main(String[] args){ new Varargs().test(); } }
What will the program print?
Select 1 option
A. 1 
B. 2 
C. 3 
D. It will not compile. 
E. Exception at runtime.