God is more interested in your spiritual growth, development of your character than a quick answer to your prayers!
It would not be hard for God to give you what you are asking for; it is a lot harder to cause changes in you and your character.
Humans tend to be so ungrateful. The people of Israel were wandering through the desert; they called out to God, He answered them, but it did not change them. Afterwards, when a different problem came they called out to God again, and He answered them and gave what they had asked for. Nevertheless, their hearts remained unchanged.
God can answer your prayers again and again, but it is not a guarantee of permanent changes in your life. Quite often God allows certain situations in our lives that help us to grow spiritually.