King James Version (KJV)
Therefore they turned {their backs} before the men of Israel unto the way of the wilderness; but the battle overtook them; and them which {came} out of the cities they destroyed in the midst of them.
Modern English
Therefore they turned their backs before the men of Israel to the way of the wilderness; but the battle followed hard after them; and those who came out of the cities destroyed them in the middle of it.
Hebrew
וַיִּפְנ֞וּ לִפְנֵ֨י אִ֤ישׁ יִשְׂרָאֵל֙ אֶל־דֶּ֣רֶךְ הַמִּדְבָּ֔ר וְהַמִּלְחָמָ֖ה הִדְבִּיקָ֑תְהוּ וַאֲשֶׁר֙ מֵהֶ֣עָרִ֔ים מַשְׁחִיתִ֥ים אוֹת֖וֹ בְּתוֹכֽוֹ׃
vayipnv lipney ʾiysh yishraʾel ʾel-derek hamidbar vhamilḥamah hidbiyqathv vaʾasher meheʿariym mashḥiytiym ʾvotvo btvokvo