Skip to content
Sharp

Core Java · interview question

Why do teams use an interface over an abstract class in production code?

Multiple choiceHardchapter-5-curatedpremiumcore-javacode-reading-with-related-types
Choose one answer
Answer and explanation

Correct answer

B. Interfaces support multiple inheritance.

Why

The primary advantage of using interfaces is that they support multiple inheritance, allowing a class to implement multiple interfaces, while a class can only extend one abstract class.

Test yourself on Core Java

A free test with instant, explained results. No account needed.

Start free test
All Core Java questions →