Another interpretation: "Who is the LORD?" (Exodus 5:2). The Holy One, blessed be He, said to him: You said "Who?" (mi). By your life, by mi you shall be stricken — for mi read backward is yam (sea); at the sea you shall know who I am. Because you said, "I do not know the LORD" (ibid.), by your life, tomorrow you shall say, "The LORD is the righteous one, and I and my people are the wicked" (Exodus 9:27). You said, "and moreover I will not let Israel go" (Exodus 5:2); by your life, tomorrow you shall take hold of the hand of each and every one to send him away. Therefore it is said, "[And it came to pass, when Pharaoh let the people go]" (Exodus 13:17).
Pharaoh's Word MI Turned to YAM at the Sea
Midrash Tanchuma Buber, Vaera 3:1
ד"א מי ה' (שמות ה ב). אמר לו הקב"ה אתה אמרת מי, חייך במי אתה לוקה, מי ים למפרע, בים אתה יודע מי אני, שאמרת לא ידעתי את ה' (שם), חייך למחר אתר אומר ה' הצדיק ואני ועמי הרשעים (שם ט כז), אתה אמרת וגם את ישראל לא אשלח (שם ה ב), חייך למחר אתה אוחז ביד כל אחד ואחד לשלחו, לכך נאמר [ויהי בשלח פרעה את העם] (שם יג יז).