your carcasses shall fall in this wilderness, and all that were numbered of you, according to your whole number, from twenty years old and upward, ye that have murmured against Me;
surely ye shall not come into the land, concerning which I lifted up My hand that I would make you dwell therein, save Caleb the son of Jephunneh, and Joshua the son of Nun.

We know that this doesn't include those under twenty; it's right there in the text. But the text also says "all that were numbered of you". When the census was taken in parshat B'midbar it only included men and it also excluded the Levi'im, because this was a census of those who could go to war.

Rashi's comment is a little confusing (I can't tell if he's including or excluding the Levi'im):

your entire number, all those…who were counted: All those counted in any census which was numbered, for example going to or returning from war, contributing shekels; all those listed in those tallies will die. They are: All those from the age of twenty and up, excluding the tribe of Levi, who were not counted from the age of twenty [but from the age of one month].

Rashi refers to the half-shekel collection. This is described in Shemot 30:12-14 and it's not clear to me who it includes. It says "when you take a census" and the censuses that are described are of soldiers; on the other hand, it also says "that there be no plague among them", and that seems like it would apply to everybody. Rashi does not clarify this.

Did women over 20 and/or Levi'im get to go into Eretz Yisrael 40 years later (those who hadn't died for other reasons by then)?

1 Answer
1

Rashi means to say that the Leviim were not killed over the forty years. It often happens that Rashi will quote the 'wrong' pasuk to simplify his point; what he is really referring to is the count at the beginning of Sefer Bamidbar, where indeed the count is described as a census of soldiers (or יוצא צבא "those who go out with the army"). This is evident from his comments on Bamidbar 1:49, where Rashi states (quoting from the Gemara in Bava Basra 121):

The Holy One Blessed Be He, foresaw that a decree would be made on all those who are counted from twenty years and upward that they will die in the desert, [so Hashem] said, "Let these [Leviim] not be included".

Regarding the women as well, Rashi writes (Parshas Pinchas, Bamidbar 26:64) that the women were not included in the decree to have to die in the desert. He happens to give a different reason, namely, "because they loved the land [of Canaan], the decree was not made upon them", but this might be an explanation as to why there was no second decree against them once there was a decree against the men.