[在线考核] 关于相对路径,以下说法中不正确的是( )。 日期:2022-11-15 18:50:24 点击:79 好评:0
7. 关于相对路径,以下说法中不正确的是( )。 A. 相对路径表述的是源端点同目标端点之间的相互位置 B. 如果在链接中源端点和目标端点位于一个目录下,则链接路径中只需要指明目标端点的文档名称即可 C. 如果在链接中源端点和目标端点不在同一个目录下,...
[在线考核] 为了将字符串str=“123,456”转换成整数123456,应该使用以下哪 日期:2022-11-15 18:49:17 点击:122 好评:0
2. 为了将字符串str=“123,456”转换成整数123456,应该使用以下哪条语句? A. int Num = int.Parse(str); B. int Num = str.Parse(int); C. int Num = (int)str; D. int Num = int.Parse(str,Globalization.NumberStyles.AllowThousands); ...
[在线考核] 如果有以下代码,哪几个数字能产生输出 "Test2" 的结果? Switc 日期:2022-11-15 18:48:08 点击:113 好评:0
1. 如果有以下代码,哪几个数字能产生输出 "Test2" 的结果? Switch(x){ case 1: System.out.println("Test1"); case 2: case 3: System.out.println("Test2"); break;} System.out.println("Test3"); } A. 0 B. 1 C. 2 D. 3 ...
[在线考核] 给定下面的类: public class Example{ String str=new S 日期:2022-11-15 18:46:50 点击:61 好评:0
9. 给定下面的类: public class Example{ String str=new String(“good”); char ch[]={'a','b','c'}; public static void main(String args[]){ Example ex=new Example(); ex.change(ex.str,ex.ch); System.out.println(ex.st...
[在线考核] 下列代码的执行结果是 public class Test { public int aMethod 日期:2022-11-15 18:45:38 点击:191 好评:0
3. 下列代码的执行结果是 public class Test { public int aMethod() { static int i=0; i++; System.out.println(i); } public static void main(String args[]) { Test test = new Test(); A. 编译错误 B. 0 C. 1 D. 运行成功,但不输出 ...
[在线考核] Java中如下哪个约束符是正确的? 日期:2022-11-15 18:44:09 点击:54 好评:0
6. Java中如下哪个约束符是正确的? A. private B. public C. protected D. protect E. friend ...
[在线考核] 下面的语句的作用是:( )。 Vector MyVector = new Vector(100 日期:2022-11-15 18:41:42 点击:51 好评:0
12. 下面的语句的作用是:( )。 Vector MyVector = new Vector(100,50); A. 创建一个数组类对象MyVector,有100个元素的空间,每个元素的初值为50。 B. 创建一个向量类对象MyVector,有100个元素的空间,每个元素的初值为50。 C. 创建一个数组类对象MyVe...
[在线考核] 如果你要读一个参数值,而该参数在<applet>标签内没有定义,则会 日期:2022-11-15 18:40:18 点击:96 好评:0
5. 如果你要读一个参数值,而该参数在
[在线考核] 已知如下代码: public class Test { public static void main(S 日期:2022-11-15 18:38:50 点击:67 好评:0
9. 已知如下代码: public class Test { public static void main(String arg[]) { int i = 5; do { System.out.println(i); } while (--i>5) System.out.println("finished"); } } 执行后的输出结果包括什么? A. 5 B. 4 C. 6 D. finished E. 什么都不...
[在线考核] 下面代码执行后的输出是什么? outer: for(int i=0;i<3; i++) in 日期:2022-11-15 18:37:32 点击:176 好评:0
4. 下面代码执行后的输出是什么? outer: for(int i=0;i<3; i++) inner: for(int j=0;j<2;j++) { if(j==1) continue outer; System.out.println(j+ “ and “+i); } A. 0 and 0 B. 0 and 1 C. 0 and 2 D. 1 and 0 E. 1 and 1 F. 1 and 2 G. 2 and 0 H...