作业视频教务托管壹叁路路贰陆陆壹〇肆〇
简答题
题目 System.out.println( “5 + 5 = ” + 5 + 5);语句的输出结果是
答案 5 + 5
题目请阅读下面的程序publ ic classTest{publ icstaticvoid main(String[] args) { int x = 3; if (x > 5){ System.out.println("a"); } else{System.out.println("b"); } } }程序的运行结果是 a.true b. false c.a d.b
答案D
题目请阅读下面的程序。 publ ic class Test{ publ icstaticvoid main(String[]args) { inta=0; int b=0; for(int i= 1; i<= 5; i++) { a = i%2;whi le (a-- >= 0){b++; } }System.out.println( “a=” +a+ “,b=” +
b); } }下列选项中哪一个是正确的运行结果 a.a=8,b=-2b.a=-2,b=8c.a=3,b=0d.a=0,b=3
答案 B
题目请阅读下面的程序publ ic classTest{publ icstaticvoid main(String[] args) { int a[ ]={2,0,4, 1,8, 3,5};int temp; for (int i =0; i < a.length - 1; i++) { for (intj=a. length- 1;j > i;j--) { if(a[j] <a[j - 1]) {temp=a[j];a[j] = a[j - 1]; a[j - 1] = temp; } } } for (Integer i : a){System.out.print(i); } } }下列选项中哪个是程序的运行结果 a.8543210b.0123458c.2041835d.以上答案都丌对
答案 B
题目请阅读下面的代码String s1=new String("abc");String s2=s1.intern(); String s3="abc";System.out.println(s1==s2);
System.out.println(s2==s3);
System.out.println(s1==s3);下列选项中程序的输出结果为 a. false true false b. false true true c. falsefalse true d. false false false
答案A
题目请阅读下面的代码classA{ intx; static inty;voidfac(String s){System.out.println( “字符串” +s); } }下
hostyun新上了香港cloudie机房的香港原生IP的VPS,写的是默认接入200Mbps带宽(共享),基于KVM虚拟,纯SSD RAID10,三网直连,混合超售的CN2网络,商家对VPS的I/O有大致100MB/S的限制。由于是原生香港IP,所以这个VPS还是有一定的看头的,这里给大家弄个测评,数据仅供参考!9折优惠码:hostyun,循环优惠内存CPUSSD流量带宽价格购买1G1核10G3...
Hostodo近日发布了美国独立日优惠促销活动,主要推送了四款特价优惠便宜的VPS云服务器产品,基于KVM虚拟架构,NVMe阵列,1Gbps带宽,默认分配一个IPv4+/64 IPv6,采用solusvm管理,赠送收费版DirectAdmin授权,服务有效期内均有效,大致约为7折优惠,独立日活动时间不定,活动机型售罄为止,有需要的朋友可以尝试一下。Hostodo怎么样?Hostodo服务器好不好?...
天上云怎么样?天上云隶属于成都天上云网络科技有限公司,是一家提供云服务器及物理服务器的国人商家,目前商家针对香港物理机在做优惠促销,香港沙田机房采用三网直连,其中电信走CN2,带宽为50Mbps,不限制流量,商家提供IPMI,可以自行管理,随意安装系统,目前E3-1225/16G的套餐低至572元每月,有做大规模业务的朋友可以看看。点击进入:天上云官方网站天上云香港物理机服务器套餐:香港沙田数据中...