Another interpretation. Why is it said, "to Moses and to Aaron"? Since it says, "And the LORD said to Moses: See, I have made you a god to Pharaoh" (Exodus 7:1), I would know only that Moses was a judge over Pharaoh. From where do I learn that Aaron too was a judge? Scripture teaches by saying "to Moses and to Aaron," comparing Aaron to Moses: just as Moses was a judge over Pharaoh, so too was Aaron a judge over Pharaoh; just as Moses spoke his words and was not afraid, so too Aaron spoke his words and was not afraid. One might think that whoever is mentioned first in the verse comes first in deed. Scripture therefore teaches, "This is Aaron and Moses," to teach you that the two of them were weighed as equal, one like the other (this is written in remez 4).
Aaron and Moses Weighed Equal Before Pharaoh
Yalkut Shimoni on Torah 179:3
דָּבָר אַחֵר. "אֶל מֹשֶׁה וְאֶל אַהֲרֹן" לָמָּה נֶאֱמַר. לְפִי שֶׁהוּא אוֹמֵר וַיֹּאמֶר ה' אֶל מֹשֶׁה רְאֵה נְתַתִּיךָ אֱלֹהִים לְפַרְעֹה, אֵין לִי אֶלָּא מֹשֶׁה דַּיָּן לְפַרְעֹה, אַהֲרֹן מִנַּיִן, תַּלְמוּד לוֹמַר "אֶל מֹשֶׁה וְאֶל אַהֲרֹן", מַקִּישׁ אַהֲרֹן לְמֹשֶׁה, מַה מֹּשֶׁה דַּיָּן לְפַרְעֹה אַף אַהֲרֹן דַּיָּן לְפַרְעֹה, מַה מֹּשֶׁה אָמַר דְּבָרָיו וְאֵינוֹ יָרֵא אַף אַהֲרֹן אָמַר דְּבָרָיו וְאֵינוֹ יָרֵא, יָכוֹל כָּל הַקּוֹדֵם בַּמִּקְרָא קוֹדֵם בְּמַעֲשֶׂה, תַּלְמוּד לוֹמַר הוּא אַהֲרֹן וּמֹשֶׁה, לְלַמֶּדְךָ שֶׁשְּׁנֵיהֶן שְׁקוּלִין זֶה כְּזֶה (כָּתוּב בְּרֶמֶז ד).