移动端

  • 题王微信公众号

    题王微信公众号

    微信搜“题王网”真题密题、最新资讯、考试攻略、轻松拿下考试

单选题

1. class A {  2. public byte file Number ( ) { 3. return l;  4. }  5. }  6.  7. Class B extends A {  8. public short getNumber( ) {  9.  return 2;  10. }  11.  12. public short getNumber( ) {  13. B b = new B( );  14. System.out.printIn(b.getNumber( ));  15. }  16. }   What is the result()?  

发布日期:2022-05-30

1. class A {  2. public byte file Number ( ) { 3. ...
A

Compilation succeeds and l is printed.

B

Compilation succeeds and 2 printed.

C

An error at line 8 cause compilation to fail.

D

An error at line 14 cause complication to fail.

E

Complication succeeds but an exception is thrown at line 14.

标签: "暂无标签"

题王网让考试变得更简单

扫码关注题王,更多免费功能准备上线!

此试题出现在

Java认证考试

SCDCD(310-081)

去刷题