When thou takest the sum of the children of Israel after their number, then shall they give every man a ransom for his soul unto the LORD, when thou numberest them; that there be no plague among them, when thou numberest them.
When you count the people of Israel by how many there are, each person must pay a ransom for their life to God at that time. This way, there won't be any plague when you count them.