Skip to content
Sharp

Object-oriented programming · interview question

Which feature of Java interfaces allows implementing classes to have method implementations?

Multiple choiceEasychapter-5-curatedpremiumoopinterfaces
Choose one answer
Answer and explanation

Correct answer

C. Default methods

Why

Default methods in interfaces allow implementing classes to have method implementations. This feature was introduced in Java 8 to enable backward compatibility.

Test yourself on Object-oriented programming

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

Start free test
All Object-oriented programming questions →