• Post Reply Bookmark Topic Watch Topic
  • New Topic

Why no multiple inheritance  RSS feed

 
rak shar
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
I m a newbie. What to answer when someone says why Java does not support multiple inheritance in classes & why they have provided multiple inheritance in interfaces
Rgrds
 
Michael Morris
Ranch Hand
Posts: 3451
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Rak,
Welcome to JavaRanch. The short answer is you don't need it. Multiple inheritance creates more problems than it solves. You can implement as many interfaces as you want which gives a similar but simpler and safer effect of multiple inheritance. Do a search here at JavaRanch and you will find this topic discussed ad nauseum.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!