Question d’entretien chez HealthStream

How would you describe dependency injection?

Réponse à la question d'entretien

Utilisateur anonyme

3 juil. 2025

I explained that dependency injection is when you pass an object into a class instead of having the class create it internally, for example, passing an Employee object into a PayrollProcessor class. This allows for better flexibility and testability. Despite giving a clear and accurate answer, the interviewer shook his head and didn’t seem to understand, likely due to a language barrier.