Skip to content
Sharp

Spring Core · interview question

Why does @Autowired in Spring matter in this design?

Multiple choiceEasychapter-9-curatedpremiumspring-corepersistence-and-validation
Choose one answer
Answer and explanation

Correct answer

B. To automatically inject dependencies

Why

@Autowired is used for automatic dependency injection in Spring. It allows Spring to resolve and inject collaborating beans into your bean.

Test yourself on Spring Core

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

Start free test
All Spring Core questions →