上海国响信息技术有限公司.doc

上传人:M****1 文档编号:561138916 上传时间:2022-10-11 格式:DOC 页数:8 大小:272.50KB
返回 下载 相关 举报
上海国响信息技术有限公司.doc_第1页
第1页 / 共8页
上海国响信息技术有限公司.doc_第2页
第2页 / 共8页
上海国响信息技术有限公司.doc_第3页
第3页 / 共8页
上海国响信息技术有限公司.doc_第4页
第4页 / 共8页
上海国响信息技术有限公司.doc_第5页
第5页 / 共8页
点击查看更多>>
资源描述

《上海国响信息技术有限公司.doc》由会员分享,可在线阅读,更多相关《上海国响信息技术有限公司.doc(8页珍藏版)》请在金锄头文库上搜索。

1、选择题 1: 1. Whatistheresultwhenyoucompileandrunthefollowingcode? 2. 3. publicclassTest 4. 5. 6. 7. publicvoidmethod() 8. 9. 10. 11. for(inti=0;i3;i+) 12. 13. 14. 15. System.out.print(i); 16. 17. 18. 19. System.out.print(i); 20. 21. 22. 23. 24. 25. Choices:What is the result when you compile and run th

2、e following code? public class Test public void method()for(int i = 0; i ” and “”. Which statement is true? A.1010 0000 0000 0000 0000 0000 0000 0000 4 give 0000 1010 0000 0000 0000 0000 0000 0000 B.1010 0000 0000 0000 0000 0000 0000 0000 4 give 1111 1010 0000 0000 0000 0000 0000 0000 C.1010 0000 00

3、00 0000 0000 0000 0000 0000 4 give 0000 0000 0000 0000 0000 0000 0000 0000 D.1010 0000 0000 0000 0000 0000 0000 0000 4 give 1111 1010 0000 0000 0000 0000 0000 0000 9:A class design requires that a member variable should be accessible only by same package, which modifer word should be used? A.protect

4、ed B.public C.no modifer D.private 10: 1. publicclassOuterClass 2. privatedoubled1=1.0; 3. /insertcodehere 4. 5. Youneedtoinsertaninnerclassdeclarationatline3.Whichtwoinnerclassdeclarationsare 6. valid?public class OuterClass private double d1 = 1.0;/insert code hereYou need to insert an inner class

5、 declaration at line 3. Which two inner class declarations arevalid?A.class InnerOne public static double methoda() return d1; B.public class InnerOne static double methoda() return d1; C.private class InnerOne double methoda() return d1; D.static class InnerOne protected double methoda() return d1; 11: 1. publicclassX 2. 3. publicObjectm() 4. 5. Objecto=newFloat(3.14F);/line3 6. 7. Objectoa=newObject1;/line4 8. 9. oa0=o;/line5 10. 11. o=null;/line6 12. 13. returnoa0;/line7 14. 15. 16. 17.

展开阅读全文
相关资源
正为您匹配相似的精品文档
相关搜索

最新文档


当前位置:首页 > 中学教育 > 其它中学文档

电脑版 |金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号