




已阅读5页,还剩1页未读, 继续免费阅读
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
苏州东峰信息工程有限公司 高级java软件工程师笔试题选择题 1:Math.round(-11.5)等於多少? A.-11 B.-12 C.-11.5 D.none 2:Which method you define as the starting point of new thread in a class from which new the thread can be excution? A.public void start() B.public void run() C.public void runnable() D.public static void main(String args) 3: 1. Whatwillbetheresultofexecutingthefollowingcode? 2. booleana=true; 3. booleanb=false; 4. booleanc=true; 5. if(a=true) 6. if(b=true) 7. if(c=true)System.out.println(Somethingsaretrueinthisworld); 8. elseSystem.out.println(Nothingistrueinthisworld!); 9. elseif(a&(b=c)System.out.println(Itstooconfusingtotellwhatistrueandwhatisfalse); 10. elseSystem.out.println(Heythiswontcompile); 11. 12. Choices:What will be the result of executing the following code? boolean a = true; boolean b = false; boolean c = true; if (a = true) if (b = true) if (c = true) System.out.println(Some things are true in this world); else System.out.println(Nothing is true in this world!); else if (a & (b = c) System.out.println(Its too confusing to tell what is true and what is false); else System.out.println(Hey this wont compile); Choices:A.The code wont compile B.Some things are true in this world will be printed C.Hey this wont compile will be printed D.None of these 4:设有变量说明语句int a=1,b=0; 则执行以下程序段的输出结果为( )。 switch (a) case 1: switch (b) case 0:printf(*0*);break; case 1:printf(*1*);break; case 2:printf(*2*);break; printf(n); A.*0* B.*0*2* C.*0*1*2* D.有语法错误 5:Which is the main() method return of a application? A.String B.byte C.char D.void 6:Which are not Java keywords? A.TRUE B.const C.super D.void 7: 1. Givethecodefragment: 2. if(x4) 3. System.out.println(“Test1”); 4. elseif(x9) 5. System.out.println(“Test2”); 6. else 7. System.out.println(“Test3”); 8. Whichrangeofvaluexwouldproduceofoutput“Test2”?Give the code fragment:if(x4)System.out.println(“Test 1”);else if (x9)System.out.println(“Test 2”);else System.out.println(“Test 3”);Which range of value x would produce of output “Test 2”? A.x4 C.x9 D.None 8:软件生命周期的瀑布模型把软件项目分为3个阶段、8个子阶段,以下哪一个是正常的开发顺序? A.计划阶段、开发阶段、运行阶段 B.设计阶段、开发阶段、编码阶段 C.设计阶段、编码阶段、维护阶段 D.计划阶段、编码阶段、测试阶段 9:Which of the following answer is correct to express the value 8 in octal number? A.010 B.0x10 C.08 D.0x8 10: 1. Whichisthemostappropriatecodesnippetthatcanbeinsertedatline18inthefollowingcode? 2. 3. (Assumethatthecodeiscompiledandrunwithassertionsenabled) 4. 5. 1.importjava.util.*; 6. 7. 2. 8. 9. 3.publicclassAssertTest 10. 11. 4. 12. 13. 5.privateHashMapcctld; 14. 15. 6. 16. 17. 7.publicAssertTest() 18. 19. 8. 20. 21. 9.cctld=newHashMap(); 22. 23. 10.cctld.put(in,India); 24. 25. 11.cctld.put(uk,UnitedKingdom); 26. 27. 12.cctld.put(au,Australia); 28. 29. 13./morecode. 30. 31. 14. 32. 33. 15./othermethods. 34. 35. 16.publicStringgetCountry(StringcountryCode) 36. 37. 17. 38. 39. 18./Whatshouldbeinsertedhere? 40. 41. 19.Stringcountry=(String)cctld.get(countryCode); 42. 43. 20.returncountry; 44. 45. 21. 46. 47. 22.Which is the most appropriate code snippet that can be inserted at line 18 in the following code?(Assume that the code is compiled and run with assertions enabled)1. import java.util.*;2. 3. public class AssertTest4. 5. private HashMap cctld;6. 7. public AssertTest()8. 9. cctld = new HashMap();10. cctld.put(in, India);11. cctld.put(uk, United Kingdom);12. cctld.put(au, Australia);13. / more code. 14. 15. / other methods . 16. public String getCountry(String countryCode)17. 18. / What should be inserted here?19. String country = (String)cctld.get(countryCode);20. return country;21. 22. A.assert countryCode != null; B.assert countryCode != null : Country code can not be null ; C.assert cctld != null : No country code data is available; D.assert cctld : No country code data is available; 11:在下述选项时,没有构成死循环的程序是 A.int i=100 while (1) i=i%100+1; if (i100) break; B.for (;); C.int k=1000; do +k; while(k=10000); D.int s=36; while (s);-s; 12:Which fragments are not correct in Java source file? A.package testpackage; public class Test/do something. B.import java.io.*; package testpackage; public class Test/ do something. C.import java.io.*; class Person/ do something. public class Test/ do something. D.import java.io.*; import java.awt.*; public class Test/ do something. 13:下面关于变量及其范围的陈述哪些是错的。 A.实例变量是类的成员变量。 B.实例变量用关键字static声明。 C.在方法中定义的局部变量在该方法被执行时创建 D.局部变量在使用前必须被初始化。 14:在软件生命周期中,下列哪个说法是不准确的? A.软件生命周期分为计划、开发和运行三个阶段 B.在计划阶段要进行问题焉醛和需求分析 C.在开发后期要进行编写代码和软件测试 D.在运行阶段主要是进行软件维护 简答题 15:串行化的注意事项以及如何实现串行化? 16:Java中异常处理有什么优点? 17:servlet的生命周期? 18:编一个程序求质数的和例如F(7)=1+3+5+7+11+13+17=58 19:spring访问底层资源使用哪个接口?说出该接口的实现类也可以。 20:两种不同的方法计算unsigned x有多少1 bits,如x=3,为0000 0011,有2个1 21: 1. classSomething 2. finalintI; 3. publicvoiddoSomething() 4. System.out.println(I=+i); 5. 6. 7. 上面代码正确还是错误?为什么。class Something final int I; public void doSomething() System.out.println(I = + i); 上面代码正确还是错误?为什么。22:循环的有序数组(比如1,2,3,4,5,-3,-2,-1这种数列)里查找一个数。 23:abstract class Name private String name; public abstract boolean isStupidName(String name) 这有何错误? 24:如何设定的weblogic的热启动模式(开发模式)与产品发布模式? 25:X博士是一个研究儿童智力开发方法的科学家,他为幼儿教育领域做出了许多贡献。最近,X博士正在研究一种适合儿童的游戏,用以辅助发展儿童的观察力、注意力和思维能力。经过连日的构思,X博士终于设计出了一种游戏:彩球游戏。 彩球游戏是一种单人参与的游戏,游戏首先给出一串由许多不同颜色的小球组成的小球序列,以及一个整数参数M(M2)。一段连续的具有相同颜色的小球序列称为连续同色序列。小孩,即游戏参与者,每次可以向任意一段连续同色序列插入一个同色小球,使该序列的长度加一。当一段连续同色序列在插入一个同色小球后其长度达到M时,该序列就会爆炸消失,然后原序列两边的其余小球会重新连成一串,如果两段相同颜色的连续同色序列在此
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 2025年环保产业项目可行性研究评估报告
- 成人教育终身学习体系构建与平台运营中的远程教育技术发展趋势报告
- 工业互联网平台数字签名技术规范与工业互联网平台数据治理报告
- 社会实践自我鉴定总结范文
- 大型公司办公室管理制度
- 泵站配电安全管理制度
- 2025年四川省遂宁市中考生物真题(原卷版)
- 土溪镇三公经费管理制度
- 加装电梯出入口管理制度
- 分公司劳务派遣管理制度
- 2025年河北省高考招生统一考试高考真题地理试卷(真题+答案)
- 疲劳恢复物理手段-洞察及研究
- 2025年河北省中考学易金卷地理试卷(原创卷)及参考答案
- 2025年时政100题(附答案)
- 2025年国家英语四级考试试题及答案
- 院感爆发考试试题及答案
- 会计核算考试题目及答案
- 2024年湖北省南漳县事业单位公开招聘教师岗考试题带答案分析
- 限高架维修合同8篇
- 全麻期间气道梗阻的预防与处理
- 工业大数据的安全与隐私保护-洞察阐释
评论
0/150
提交评论