But, indeed, for this reason I have allowed you to remain, in order to show you My power and in order to proclaim My name through all the earth.One of the hardest questions to answer a nonbeliever is "Why does God let bad things happen to good people?" While I realize that Pharaoh doesn't exactly fall into the category of "good," I think this verse still shows a glimmer of an answer.
I have to be careful how I state this, due to the sovereignty-vs-freewill issue, but I'll put it like so: God will sometimes allow bad things to happen, or even lead us to bad things, so that he can show His power in delivering us from those circumstances. I'm not saying this is always the case, or that bad things are always from God. However, God sometimes will lead us through the valley to show that he is in control, and that he can bring us out again.
Also, he will sometimes cause bad things to happen to nonbelievers in an attempt to show them the error of their ways, and bring them to Him at long last. Many people have to hit rock bottom, and exhaust their own strength and abilities, before they are willing to consider that they are not the center of the universe, and need help from Him.
Also, consider that God could very well have annihilated the Egyptians at any time, leaving the Hebrews free to do what they wanted. But God did not do this. He specifically left them alive, though suffering, as a testament to His power and the care He had for His people.