When we are children, innocent, we have no bad habits, but as we grow and associate with bad company, we also acquire all these bad habits. So to give up all these bad habits means we have to associate with sadhus or devotees, saintly persons. Then we can give it up. This is called anartha-nivrtti, means giving up all unwanted bad habits.
From Srila Prabhupada’s lecture on Bhagavad-gita 2.11 (with Spanish translator) — 11 February, 1975