And when she had opened it, she saw the child: and, behold, the babe wept. And she had compassion on him, and said, This is one of the Hebrews’ children. – Exodus 2:6
The very means which Pharaoh devised for the effectual crushing of the people-the destruction of the male children-became the direct, nay, the divine provision for educating a deliverer for them. Moses had never been, in all probability, trained in the courts of Pharaoh if he had not been put in the basket of bulrushes on the brink of the Nile; and his mother would certainly never have put him there if there had not been a pitiless edict that the male children should be put to death. Moved by maternal instinct to save her child and moved by faith in God not to obey the king’s command, she places her child in the ark. Pharaoh’s daughter finds the child, compassionates its cry, extricates it from peril, loves it fondly, adopts it capriciously, and educates it in the very court of Pharaoh. That child grows up to be the man who should vex the fields of Zoan-the man of God, who with a high hand and an outstretched arm, would lead forth the slaves of Egypt to become a great nation, which God should bless. So you see the Lord in all points meets Pharaoh and foils him. This Pharaoh was the great representative in those days of the power of evil, and he stands still to the Christian church as the type of the seed of the serpent. But the Lord withstands him, despoils him of his purpose, and turns all he does to the very highest and best end. Such the narrative, full of instruction, and charged with portent, that serves as a type of the Lord’s doing when He makes bare His arm for the salvation of His own heritage. ~ C.H. Spurgeon
https://www.blueletterbible.org/Comm/spurgeon_charles/sermons/0997.cfm