making code loosely coupled