וּקְבָרוּם֙ בֵּ֣ית יִשְׂרָאֵ֔ל לְמַ֖עַן טַהֵ֣ר אֶת־הָאָ֑רֶץ שִׁבְעָ֖ה חֳדָשִֽׁים׃
And seven months shall the house of Israel be burying them, that they may cleanse the land.
Read midrashic interpretation of Ezekiel 39:12: and classical rabbinic exegesis.