Multiple choice technology architecture

Identify the difference between a library and framework

  1. Library will have a default behaviour whereas frameworks will not have a default behaviour

  2. Library can be extended easily whereas extending framework is complex and resource consuming

  3. Library code, in general, is not allowed to be modified

  4. The program's flow of control is dictated by the framework

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

The key difference is control flow: in a library, your code controls execution (you call library functions). In a framework, the framework controls execution and calls your code at specific points (hooks, callbacks). Option D captures this. Options A, B, and C are false - libraries don't necessarily have default behavior, extensibility varies by design, and library code can often be modified if source-available.