类 MyClass 中有下列方法定义: public void testParams(params int[] arr) { Console.Write ("使
类 MyClass 中有下列方法定义: public void testParams(params int[] arr) { Console.Write ("使用 Params 参数!"); } public void testParams(int x,int y) { Console.Write ("使用两个整型参数!"); } 请问上述方法重载有无二义性?若没有,则下列语句的输出为()。 MyClass x = new MyClass(); x.testParams(0); x.testParams(0,1); x.testParams(0,1,2);
A、有语义二义性;
B、使用 Params 参数!使用两个整型参数!使用 Params 参数!
C、使用 Params 参数!使用 Params 参数!使用 Params 参数!
D、使用 Params 参数!使用两个整型参数!使用两个整型参数!