Hope is vital for our survival. When we lose hope we may turn to false gods/idols and addictions. Above all our greatest need is a right relationship with God, and this can only be achieved through a relationship with Jesus.
In this passage we see God heard their cries, remembered their convenent (if God has promised something in scripture, we can be fully confident that He will fulfill it), and he knew/cared.
When going through a trial, hae hope and pray to God. If He doesn't deliver you right away from the trouble, pray for strength to endure. Be careful what you choose to focus on, if it's always about the problem you'll lose sight of the God who has already done much for us.