网友您好, 请在下方输入框内输入要搜索的题目:
题目内容
(请给出正确答案)
在没有导入标准库math的情况下,语句x = 3 or math.sqrt(9)也可以正常执行,并且执行后x的值为3。
参考答案和解析
错误
更多 “在没有导入标准库math的情况下,语句x = 3 or math.sqrt(9)也可以正常执行,并且执行后x的值为3。” 相关考题
考题
设有如下程序: public class Sun { public static void main (String args[ ]) { int x,y; x= (int) Math.sqrt (2) /2+ (int) Math.random ()*2/2; y= (int) Math.sqrt (3) /3+ (int) Math.random ()*3/3; 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>yB.x=yC.x<yD.以上都不对
考题
下面程序段的输出结果是( )。 publicclassTest{ publicstaticvoidmain(Stringargs[]){ intx,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.println9"x>y"); elseif(x==y) System.out.println("x=y"); else System.out.println("x<y"); } }A.x>yB.x=yC.x<yD.编译错误
考题
填空题语句x=3==3,5执行结束后,变量x的值为()。
热门标签
最新试卷