[for] forty years.
Al-Kalbi said:
When they said: "We will never enter it ever," God said: "So indeed, it is forbidden to them forever," and along with that, they wandered in the earth for forty years. He said: None of those who were with Moses entered it; they all perished in the wilderness, except for two men: Joshua son of Nun and Caleb. During those forty years, He sent down upon them manna and quails, and garments that would neither wear out nor become soiled, growing with the young, and sandals that would not wear out. This was for them in their wilderness until they entered Jericho.
Yahya said: Their children entered it, along with Joshua son of Nun and Caleb.
Mujahid said: The meaning of "they wander through the earth" is that they would wake up where they spent the evening, and spend the evening where they woke up. And in that wilderness of theirs, Moses struck the rock for them. Surah al-Ma'idah from verse (27) to verse (31).
أَرْبَعِينَ سَنَةً.
قَالَ الْكَلْبِيُّ:
لَمَّا قَالُوا: إِنَّا لَنْ نَدْخُلَهَا أَبَدًا، قَالَ اللَّهُ: فَإِنَّهَا مُحَرَّمَةٌ عَلَيْهِمْ أَبَدًا، وَهُمْ مَعَ ذَلِكَ يَتِيهُونَ فِي الْأَرْضِ أَرْبَعِينَ سَنَةً. قَالَ: فَلَمْ يَدْخُلْهَا أحدٌ مِمَّنْ كَانَ مَعَ مُوسَى، هَلَكُوا (أَجْمَعُونَ) فِي التِّيهِ إِلَّا رَجُلَيْنِ: يُوشَعُ بْنُ نُونٍ، وَكَالُوبُ، وَأَنْزَلَ عَلَيْهِمْ فِي تِلْكَ الْأَرْبَعِينَ سَنَةً الْمَنَّ وَالسَّلْوَى، وَثِيَابًا لَا تُخَرَّقُ وَلَا تُدَنَّسُ تَشِبُّ مَعَ الصَّغِيرِ، وَخِفَافًا لَا تُخَرَّقُ، فَكَانَ لَهُمْ ذَلِكَ فِي تِيهِهِمْ؛ حَتَّى دَخَلُوا أَرِيحَا.
قَالَ يحيى: دَخَلَهَا أَبْنَاؤُهُمْ، وَيُوشَعُ بْنُ نُونٍ وَكَالُوبُ.
قَالَ مُجَاهِدٌ: وَمَعْنَى ﴿يتيهون فِي الأَرْض﴾ كَانُوا يُصْبِحُونَ حَيْثُ يُمْسُونَ، ويُمْسُونَ حَيْثُ يُصْبِحُونَ، وَفِي تِيهِهِمْ ذَلِكَ ضرب لَهُم مُوسَى الْحجر. سُورَة الْمَائِدَة من الْآيَة (٢٧) إِلَى الْآيَة (٣١).