← Quiz: OOP Interview Questions: all 10 questions
Quiz: OOP Interview Questions · Question 4 of 10
Why doesn't Java allow multiple inheritance of classes?
Why doesn't Java allow multiple inheritance of classes?
- A.It's slower
- B.To avoid the diamond problem's ambiguity
- C.Interfaces don't exist in Java
- D.Because of garbage collection
Answer & explanation
Correct answer: To avoid the diamond problem's ambiguity
Two parents could provide conflicting implementations.
Can you get the rest right without peeking?
Take the timed Quiz: OOP Interview Questions quiz free. Pass it to earn XP and count towards your certificate.
Start the quiz →