← Quiz: SOLID in Java: all 10 questions
Quiz: SOLID in Java · Question 8 of 10
Dependency Inversion says high-level modules should depend on:
Dependency Inversion says high-level modules should depend on:
- A.Concrete low-level classes, to avoid extra interfaces
- B.The database driver directly
- C.Static utility methods
- D.Abstractions (interfaces) that the low-level classes implement
Answer & explanation
Correct answer: Abstractions (interfaces) that the low-level classes implement
Both sides depend on the interface, so the low-level detail can be swapped.
Can you get the rest right without peeking?
Take the timed Quiz: SOLID in Java quiz free. Pass it to earn XP and count towards your certificate.
Start the quiz →