- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Why multiple inheritance is not supported by Java?
Multiple inheritances lead to ambiguity.
For example, if there is a class named Sub and there are two classes Super1 and Super2 and if both contains a method named sample().
And if the class sub inherits both classes Super1 and Super2 then there will be two copies of the sampling method one from each superclass and it is ambiguous to decide which method to be executed.
- Related Articles
- Why multiple inheritance is not supported in Java
- Why is operator overloading not supported by java?
- Multiple inheritance by Interface in Java
- Java and multiple inheritance
- Does Java support multiple inheritance? Why? How can we resolve this?
- Java Program to Implement Multiple Inheritance
- How multiple inheritance is implemented using interfaces in Java?
- What is diamond problem in case of multiple inheritance in java?
- C# and Multiple Inheritance
- Multiple Inheritance in C++
- Multiple inheritance in JavaScript
- Does Python support multiple inheritance?
- Difference Between Single and Multiple Inheritance
- Inheritance in Java
- How to resolve - Relative path is not supported in PowerShell DSC?

Advertisements