Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Abstract class and interface... Superclass

 
Larry Lai
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi everyone,

I've a homework execrise about that...

1. In what situation would we use an abstract class instead of an interface?

2. In what situation would we use an interface instead of an inheriting from a superclass?

3. When is it better to use an interface rather than an abstract class?

How to think that three kinds of keywords?
Thanks
Larry
 
Barry Gaunt
Ranch Hand
Posts: 7729
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Homework Help No, Java Tutorial Yes
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic