Inversion of control is a principle and dependency injection is a way of implementing inversion of control.