首页
外语
计算机
考研
公务员
职业资格
财经
工程
司法
医学
专升本
自考
实用职业技能
登录
计算机
下面程序段的输出结果是( )。 public class Test { public static void main(String args[ ]){ int x,y; x=(int)Mat
下面程序段的输出结果是( )。 public class Test { public static void main(String args[ ]){ int x,y; x=(int)Mat
admin
2013-03-01
25
问题
下面程序段的输出结果是( )。 public class Test { public static void main(String args[ ]){ int x,y; x=(int)Math.sqrt(5)/2+(int)Math.random()*5/2; y=(int)Math.sqrt(3)/2+(int)Math.random()*3/2; if (x>y) System.out.println("x>y"); else if (x==y) System.out.println("x=y"); else System.out.println("x<y"); } }
选项
A、x>y
B、x=y
C、x<y
D、编译错误
答案
1
解析
转载请注明原文地址:https://kaotiyun.com/show/Ew2p777K
本试题收录于:
二级Java题库NCRE全国计算机二级分类
0
二级Java
NCRE全国计算机二级
相关试题推荐
在Java中,和数据连接的机制是______。
在ODBC标准中,允许使用的数据库连接标准是______。
下列嵌套的循环程序执行后,结果是______。publicclassax25{publicstaticvoidmain(String[]args){
下列程序执行的结果是______。publicclassexl3{publicstaticvoidmain(String[]args){int
下列______不是面向对象程序设计方法的特点。
软件需求分析阶段的工作可以分为四个方面:需求获取、需求分析、编写需求规格说明书以及______。
在J2SDK的基本命令中,______用来生成C头文件和Stub文件。
下列关于继承()叙述是正确的。
下列哪个包封装抽象窗口工具包,提供管理用户图形界面功能?
随机试题
恒发公司为在上海证券交易所主板挂牌的上市公司,明方公司持有恒发公司30%的股份,是其控股股东。2018年8月,明方公司管理层与朱亚集团接触,拟将其持有的恒发公司全部股份转让给朱亚集团。8月16日,市场出现传闻,称明方公司拟将其持有的恒发公司股份售出以偿还
患者女性,74岁。腰背部疼痛六个月前来就诊,体检:肝肋下2cm,脾肋下3cm,多个腰椎骨压痛明显。实验室检查:血红蛋白85g/L,白细胞4.6×10。9/L,血小板110×109/L,血沉120mm/h,尿蛋白定性(﹢),24小时尿蛋白定量5g。BUN15
既可以清肺火、清胃火,又可泻肾火的中药是
考虑诊断为化疗后10天死亡,最可能的死亡原因是
A.青霉素GB.氨基糖苷类C.大环内酯类D.头孢菌素类E.四环素类治疗流行性脑脊髓膜炎宜首选
对于已经生效的合同,如发现合同条款空缺,致使合同难以履行,则对于合同有关内容的确定方法,下列表述中正确的是( )。
若f(x)=,则f"(0)=
法律所具有的、通过其规定和实施而影响人们思想,培养和提高人们法律意识,引导人们依法行为的作用。这是法律规范的
下列叙述中错误的是
BonAppetiteA)Wealllovethefoodwegrowupon,butwealsoseekadventureinthefoodwehavenevertasted.Ahugelypopular
最新回复
(
0
)