Before Moshe dies, God tells him that althoughhe will not be allowed to enter the Holy Land, he will be able to see the entire expanse of the land from the top of Mount Nebo. Moshe ascends the mountain and is shown the land from one end to the other. (Devarim: 34, 1-4). As Rabbi Zalman Soritzkin points out in his Aznayim LeTorah, it is not possible for a regular human being to see the entire expanse of the Holy Land with his unaided vision, and, therefore, there was undoubtedly a miracle involved here. Perhaps we can suggest that Moshe was able to see the entire land through the 'or haganuz,' the hidden light that remained from the six days of creation. Rashi, in his commentary to Bereishis (4:1) mentions the midrash that the God stored away the original light from the first day of creation because the wicked people of this world were not worthy of benefiting from it. This light functioned until day four of creation, when it was replaced by the sun, the moon and the other luminaries. God stored the original light away for the future, when the tzaddikim - the righteous people - will enjoy it. However, as Rav Kook points out, over the course of the the generations, there are certain tzaddikim who are able to see this hidden light in this world. Perhaps, then, God enabled Moshe to see the entire land from the mountain top through this hidden light. In this way, we can connect the end of the Torah, in parshas VeZos HaBeracha, with the beginning of the Torah, in parshas Bereishis.
Rashi, citing a midrash, says that Moshe was also shown the future history of the nation in the land, viewing the land in its tranquility, as well as the oppressors who would arise against it. Rabbi Jacob Rabinowitz, former dean of Jewish Studies at Yeshiva University, in his work Yemin Yaakov, asks, why did God show Moshe the bad parts of his nation's history at this point in time, just before his death, when it would certainly cause him anguish? Did God just want to make Moshe suffer at this point of his life?! Rabbi Rabinowitz offers three answers.First, he says that since God's trademark, or seal, is truth He could not give Moshe a false impression of the nation's history and make him think that everything would go smoothly. Secondly, when Moshe would see the more uncomfortable aspects of the nation's future, he would pray on their behalf. Finally, Rav Yisroel Salanter teaches that when God judges people, He takes into account the suffering that those around them experience due to the punishment of their loved ones, He mitigates the suffering of the one being judged because his acquaintances do not deserve to suffer so much. Thus, by showing Moshe the darker parts of the nation's future, the judgment of the nation would be lightened. I would like to suggest yet another explanation for God's showing Moshe the entire future of his nation, based on the Ramban's explanation of why God showed Moshe the land in the first place.
The Ramban says that the reason God showed Moshe the entire land is that Moshe loved the Jewish people, and wanted to see the reward that God had in store for them when they would settle the land of their forefathers. From this perspective, we can understand why God also showed Moshe the enter history of the nation, including both its good times and its bad times. When someone loves another, he wants to know everything about the person, both the good and the bad. Although the bad aspects may cause the one who loves some anguish, in a deeper sense they only serve to strengthen the love held for the other, and the bad times may serve to strengthen that love even more than the good times do. God, therefore, showed Moshe, the true lover of the Jewish people, all that would befall them in the future just as he was about to die, to endear them to him even more, so that he could take that love with him as God removed him from their midst.