Skip to content
Sharp

Software Architecture · interview question

When using the Observer Pattern, what role does the 'subject' play?

Multiple choiceMediumchapter-13-curatedpremiumsoftware-architectureobserver-pattern
Choose one answer
Answer and explanation

Correct answer

C. It keeps track of observers and notifies them of changes.

Why

In the Observer Pattern, the subject maintains a list of observers and notifies them of any changes, acting as the central point of communication for event-driven updates.

Test yourself on Software Architecture

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

Start free test
All Software Architecture questions →