移动端

  • 题王微信公众号

    题王微信公众号

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

单选题

现有:  1.  interface Animal  f      2.    void eat();      3.    }      4.  5.  // insert code here      6.  7. public class HouseCat implements Feline  {      8.    public void eat()    {  }     9.  }  和以下三个接口声明:  interface Feline extends Animal  (  )  interface Feline extends Animal  {void eat();    }  interface Feline extends Animal  {void eat()    {  }  }   分别插入到第5行,有多少行可以编译?   

发布日期:2020-04-10

现有:  1.  interface Animal  f      2.    void eat()...
A

0

B

1

C

2

D

3

题王网让考试变得更简单

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

此试题出现在

CMS专题

CMS专题

去刷题
热门试题热门资讯 相关试题

暂无相关推荐~

接口Animal定义如下: public interface Animal {void Move();} 则下列抽象类的定义中,哪些是不合法的?()

interface Animal {  void soundOff();  }  class Elephant implements Animal {  pub...

1. interface Animal {   2. void eat();   3. }   4.   5. // insert code here   6....

现有:  1.  interface Animal  f      2.    void eat();      3.    }      4.  5.  //...

现有:  1. interface Animal {  2. void eat();  3. }  4.  5. // insert code here  6....

现有:  interface Animal {       void eat () ;       }       //insert code here    ...

现有:   1. interface Animal {    2.   void eat();   3.  }    4.   5. // insert cod...

1. interface A { public void aMethod(); }  2. interface B { public void bMethod(...

在Java中,类Animal中的方法printA()定义如下:  public void printA() {    Int a=10;    Int resu...

在Java中,类Animal中的方法printA()定义如下:  public void printA() {    Int a=10;    Int resu...