Identifying infected people early and treating them with medications is one of the most effective ways to prevent TB from spreading.