当前位置: 技术问答>java相关
scjp(13)
来源: 互联网 发布时间:2015-02-15
本文导语: Question 64: Returning a value of false in Java 1.0.2 from an event handler: Select the one right answer. a) passes that event is passed up the container hierarchy b) stops that event from being passed up the container hierarchy c) has no...
Question 64: Returning a value of false in Java 1.0.2 from an event handler:
Select the one right answer.
a) passes that event is passed up the container hierarchy
b) stops that event from being passed up the container hierarchy
c) has no effect on whether the event is passed up the container heirarchy
为什么选B。这种题SCJP不会考吧
Question 51: Given these code snippets:
Boolean b1 = new Boolean(true);
Boolean b2 = new Boolean(true);
Which expressions are legal Java expressions that return true?
Select all valid answers.
a) b1 == b2
b) b1.equals(b2)
c) b1 & b2
d) b1 | b2
e) b1 && b2
f) b1 || b2
答案是B。C,D,E,F为什么不对?
Select the one right answer.
a) passes that event is passed up the container hierarchy
b) stops that event from being passed up the container hierarchy
c) has no effect on whether the event is passed up the container heirarchy
为什么选B。这种题SCJP不会考吧
Question 51: Given these code snippets:
Boolean b1 = new Boolean(true);
Boolean b2 = new Boolean(true);
Which expressions are legal Java expressions that return true?
Select all valid answers.
a) b1 == b2
b) b1.equals(b2)
c) b1 & b2
d) b1 | b2
e) b1 && b2
f) b1 || b2
答案是B。C,D,E,F为什么不对?
|
64题我认为不应该考,已经被淘汰的事件处理模型了。
51:
c、&是按位与,操作数是整型的,int,short,long等,不能对对象使用
d、同上,按位或
e、&&操作的操作数只能是boolean变量或表达式。
f、同上
51:
c、&是按位与,操作数是整型的,int,short,long等,不能对对象使用
d、同上,按位或
e、&&操作的操作数只能是boolean变量或表达式。
f、同上
您可能感兴趣的文章:
本站(WWW.)旨在分享和传播互联网科技相关的资讯和技术,将尽最大努力为读者提供更好的信息聚合和浏览方式。
本站(WWW.)站内文章除注明原创外,均为转载、整理或搜集自网络。欢迎任何形式的转载,转载请注明出处。
本站(WWW.)站内文章除注明原创外,均为转载、整理或搜集自网络。欢迎任何形式的转载,转载请注明出处。