java基础题目

java基础题目

ID:44811688

大小:1.81 MB

页数:52页

时间:2019-10-29

java基础题目_第1页
java基础题目_第2页
java基础题目_第3页
java基础题目_第4页
java基础题目_第5页
资源描述:

《java基础题目》由会员上传分享,免费在线阅读,更多相关内容在行业资料-天天文库

1、题库:Java基础    章节:第03章Java语言基础_01数据类型_02    题型:一级难度Java基础 1如下哪些不是java的关键字A.java B.     NULL C.  false D.   this A,B,题库:Java基础    章节:第01章开发简单JAVA应用程序程序    题型:一级难度Java基础 2. main方法是JavaApplication程序执行的入口点,关于main方法的方法头以下哪项是不合法的A.publicstaticvoidmain()           B.publicstaticvoidmain(Stringargs)C.pu

2、blicstaticintmain(String[]args) D.publicvoidmain(Stringargs) A,B,C,D,题库:Java基础    章节:第03章Java语言基础_02运算符和表达式+控制语句_02    题型:一级难度Java基础 3.下面哪些声明是合法的A.longi=4990   B.inti=4LC.floatf=1.1     D.doubled=34.4A  B  C  D  标记答案记录 A,D,题库:Java基础    章节:第03章Java语言基础_02运算符和表达式+控制语句_02    题型:一级难度Java基础 4.设floa

3、tx=1,y=2,z=3,则表达式y+=z--/++x的值是A.3.5      B.3    C.4      D.5A  B  C  D  标记答案记录 A,题库:Java基础    章节:第03章Java语言基础_02运算符和表达式+控制语句_02    题型:一级难度Java基础 5. Whatwillhappenwhenyouattempttocompileandrunthiscode?(  )publicclassSomething{      publicstaticvoidmain(Stringargv){             System.out.printl

4、n("hellocruelworld");      }}A)ThecompilerwillcomplainthatmainisareservedwordandcannotbeusedforaclassB)Thecodewillcompileandwhenrunwillprintout"hellocruelworld"C)ThecodewillcompilebutwillcomplainatruntimethatnoconstructorisdefinedD)Thecodewillcompilebutwillcomplainatruntimethatmainisnotcorrect

5、lydefinedA  B  C  D  标记答案记录 D,题库:Java基础    章节:第03章Java语言基础_02运算符和表达式+控制语句_02    题型:一级难度Java基础 6. Whichofthefollowingwillcompilecorrectly?(  )A)shortmyshort=99s;B)stringname='excellenttutorialmrgreen';C)charc=17c;D)intz=15;A  B  C  D  标记答案记录 D,题库:Java基础    章节:第03章Java语言基础_02运算符和表达式+控制语句_02    题

6、型:一级难度Java基础 7.Whatwillhappenwhenyouattempttocompileandrunthefollowingcode?(  )             intoutput=10;             booleanb1=false;             if((b1==true)&&((output+=10)==20)){                    System.out.println("weareequal"+output);             }else{                    System.out.pr

7、intln("notequal!"+output);             }A)compileerror,attemptingtopeformbinarycomparisononlogicaldatatypeB)compilationandoutputof"weareequal10"C)compilationandoutputof"notequal!20"D)compilationandoutputof"notequal!10"A  B  C  D  标记答案记录

当前文档最多预览五页,下载文档查看全文

此文档下载收益归作者所有

当前文档最多预览五页,下载文档查看全文
温馨提示:
1. 部分包含数学公式或PPT动画的文件,查看预览时可能会显示错乱或异常,文件下载后无此问题,请放心下载。
2. 本文档由用户上传,版权归属用户,天天文库负责整理代发布。如果您对本文档版权有争议请及时联系客服。
3. 下载前请仔细阅读文档内容,确认文档内容符合您的需求后进行下载,若出现内容与标题不符可向本站投诉处理。
4. 下载文档时可能由于网络波动等原因无法下载或下载错误,付费完成后未能成功下载的用户请联系客服处理。