Devarim31:12

הַקְהֵל אֶת־הָעָם הָאֲנָשִׁים וְהַנָּשִׁים וְהַטַּף וְגֵרְךָ אֲשֶׁר בִּשְׁעָרֶיךָ לְמַעַן יִשְׁמְעוּ וּלְמַעַן יִלְמְדוּ וְיָרְאוּ אֶת־יְהוָה אֱלֹהֵיכֶם וְשָׁמְרוּ לַעֲשׂוֹת אֶת־כָּל־דִּבְרֵי הַתּוֹרָה הַזֹּאת׃

Assemble the people, the men and the women and the little ones, and the stranger who is within your gates, so that they may hear and so that they may learn, and fear the Eternal your Almighty, and take care to do all the words of this Torah.

Devarim 31:12

הַקְהֵל אֶת־הָעָם הָאֲנָשִׁים

Devarim / Deuteronomy 31:12 · Remez

Devarim 31:12

הַקְהֵל אֶת־הָעָם הָאֲנָשִׁים וְהַנָּשִׁים וְהַטַּף וְגֵרְךָ אֲשֶׁר בִּשְׁעָרֶיךָ לְמַעַן יִשְׁמְעוּ וּלְמַעַן יִלְמְדוּ וְיָרְאוּ אֶת־יְהוָה אֱלֹהֵיכֶם וְשָׁמְרוּ לַעֲשׂוֹת אֶת־כָּל־דִּבְרֵי הַתּוֹרָה הַזֹּאת׃

Assemble the people, the men and the women and the little ones, and the stranger who is within your gates, so that they may hear and so that they may learn, and fear the Eternal your Almighty, and take care to do all the words of this Torah.

Remez רֶמֶז

Twice "so that"

When one word is repeated twice in a single phrase, a reader of the Torah looks for the reason. Here "so that" (לְמַעַן) appears twice, while the next verse says it more briefly. Torah scholars see in the repetition a hint at different duties of the listeners.

Or HaChaim: the first "so that they may hear" is for everyone: both men and women must hear the commandments they keep. The second, "so that they may learn", is a separate part, the study of Torah, and that is the men's duty. Netziv: it does not say "so that they learn to fear". Fear of the Eternal enters the heart by itself when the Torah is heard at the assembly in the Temple.

How Or HaChaim and Haamek Davar explain it

Or HaChaim Assemble the people and so on, so that they may hear and so that they may learn

We need to understand why the word "so that" (לְמַעַן) is doubled. It would have been enough to say "so that they may hear and learn", as the next verse says: "they will hear and learn" (Devarim / Deuteronomy 31:13).

Or HaChaim The men and the women and the little ones

It seems the point is that Scripture said: "Assemble the people, the men and the women and the little ones", to read the Torah scroll aloud to them. And we already know that women are not obligated in Torah study, for it is written: "And you shall teach them to your sons" (Devarim / Deuteronomy 11:19), and our sages, of blessed memory, expounded: "but not your daughters" (Kiddushin 29b).

Or HaChaim So that they may hear

Therefore Scripture divided this commandment into two levels. First it named the part that is the same for men and women: "so that they may hear". That is, so that they hear the commandments of the Torah that they are obligated to do, and in this they are equal. For women too are obligated in the prohibitions and in the positive commandments not bound to a time.

Or HaChaim And so that they may learn

And afterwards it named a separate part, for the men alone: "and so that they may learn", that is, Torah study. That is why it does not say "so that they may hear and learn": then one would understand that both parts are one duty for all.

Haamek Davar And fear the Eternal

It does not say "so that they learn to fear", for here it speaks of adults who understand what fear of the Eternal is. But the very hearing of this portion at the assembly and in the chosen House works on the heart, and they attain fear of the Eternal.

Takeaway

Verse 31:12 has "so that they may hear and so that they may learn" (לְמַעַן יִשְׁמְעוּ וּלְמַעַן יִלְמְדוּ), verse 31:13 has "they will hear and learn" (יִשְׁמְעוּ וְלָמְדוּ). The repeated "so that" is the hint.
Positive commandments bound to a time are those done at a set time, such as the sukkah or the shofar. Women are exempt from most of them.
The chosen House is the Temple in Jerusalem. The assembly (Hakhel) was held there, and the king read to the people from the book of Devarim.
Netziv reads the word order: "so that they may learn, and fear". Fear stands apart from learning, it is not a subject of the lesson but what is born from what was heard.