A为什么不对,F为什么对?

wisjeremy 2008-06-20 07:42:12

A为什么不对,F为什么对?
Question 148
Which three statements are true? (Choose three.)
A. A final method in class X can be abstract if and only if X is abstract.
B. A protected method in class X can be overridden by any subclass of X.
C. A private static method can be called only within other static methods in class X.
D. A non-static public final method in class X can be overridden in any subclass of X.
E. A public static method in class X can be called by a subclass of X without explicitly referencing the class X.
F. A method with the same signature as a private final method in class X can be implemented in a subclass of X.
G. A protected method in class X can be overridden by a subclass of A only if the subclass is in the same package as X.
Answer: BEF
...全文
122 5 打赏 收藏 转发到动态 举报
写回复
用AI写文章
5 条回复
切换为时间正序
请发表友善的回复…
发表回复
dracularking 2008-06-20
  • 打赏
  • 举报
回复
as we know, final method cannot be overridden so as not to be implemented and abstract method must be implemented in a child concrete class, so they two are against each other, just unable to appear together.

and private final method has nothing to do with the method with the same signature (has same parameter, return type etc. ) in its extended class, so it can be implemented
wisjeremy 2008-06-20
  • 打赏
  • 举报
回复
signature
特征
貌似可以解释成修饰符
A method with the same signature as a private final method
就是这个method是private的final的
ryan0629 2008-06-20
  • 打赏
  • 举报
回复
A: final方法不能被重写,所以不能为abstract
F: the same signature 不很清楚这里的signature 具体怎么译
gongyali2005 2008-06-20
  • 打赏
  • 举报
回复
基础问题.

但对我英文不太感冒.

62,614

社区成员

发帖
与我相关
我的任务
社区描述
Java 2 Standard Edition
社区管理员
  • Java SE
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧