"And when Pharaoh drew near, the Children of Israel lifted their eyes, and, behold! The Egyptians were marching after them, and they were terrified, and the children of Israel cried out unto the Lord." 1
Ba’al Hatoldot learns a unique lesson from this pasuk. He says, "Sometimes after people have already gotten into trouble they try to run away from it as if it doesn’t exist in the place they're escaping to. To explain how wrong this act is, he says it's like a pregnant woman suffering from pain and running somewhere as if the pain has any connection to the place where she's standing, misunderstanding that the pain is inside her body and stays with her wherever she goes.
This pasuk gives us a better solution. The people of Israel had already left Egypt. However, they got to the Red Sea, looked backwards, and guess who was there? The Egyptians! Suddenly the People of Israel started to feel as if they weren’t able to get rid of the Egyptians who were chasing them everywhere. Then they realized that the right solution was to pray to God so that he will remove the threat, and not for them to keep running away from it without success
And many evils and troubles shall come upon them; so that they will say in that day: Are not these evils come upon us because our God is not among us? 2
The Ba’al Hatoldot brings this pasuk and then he explains: "It has to be clear to everyone that God is among them. When a person gets to a point where he asks himself if God is with him, the trouble starts. How does it work? It's simple. If you believe, and live your life feeling that God is with you, He takes part in your trouble and then you are never alone. If someone is sharing it with you, and it is God, it then becomes his problem too and he will find the solution.
This is exactly what we see at the end of our weekly portion:
 And the name of the place was called Massah, and Meribah, because of the striving of the children of Israel, and because they tried the Lord, saying: 'Is the Lord among us, or not?  Then came Amalek, and fought with Israel in Refidim. 3