What is output by the following code? 以下代码输出什么? int a = 11; System.out.println(a / 2);单项选择题
A
11 11
B
6
C
5.5
D
5
E
6.5
登录即可查看完整答案
我们收录了全球超50000道真实原题与详细解析,现在登录,立即获得答案。
类似问题
What is the ending value of y? int x; int y; x = 2; y = ((x + 1) / 5) + (x / 2) ;
What is the ending value of y? int x; int y; x = 2; y = ((x + 1) / 5) + (x / 2) ;
What is the ending value of x? int y = 6; x = (1 / 2) * y + 8;
Question textDefine a function named withoutLastDigit that when passed an integer, returns its last digit. Please see the test cases for examples. Some trivial test cases are hidden to combat hard-coding.For example:[table] Test | Result int a = 1729; println(withoutLastDigit(a)); | 172 int x = -35; println(withoutLastDigit(x)); | -3 [/table] Answer:(penalty regime: 0 %)Ace editor not ready. Perhaps reload page?Falling back to raw text area.Check Question 3
更多留学生实用工具
希望你的学习变得更简单
加入我们,立即解锁 海量真题 与 独家解析,让复习快人一步!