Q:

下列程序片段中,能通过编译的是:

A .publicabstractclassAnimal{
  publicvoidspeak();}


B .publicabstractclassAnimal{
  publicvoidspeak(){}}


C .publicclassAnimal{
  publicabstractvoidspeak();}


D .publicabstractclassAnimal{
  publicabstractvoidspeak(){}}

对0人提供帮助

正确答案:B