Allah, the Exalted, informs about mankind and the blameworthy characteristics that he possesses, except for those believing servants upon whom Allah has bestowed His mercy. Allah explains that when any hardship befalls man, after he has experienced blessings, he is disheartened and he despairs of any good in the future. He denies and rejects (the bounties of) his previous condition. Thus, he behaves as if he has never seen any good and he loses all hope for relief (from his situation):
And if We give man a taste of Mercy from Us, and then withdraw it from him, verily! he is despairing, ungrateful. (9)
But if We let him taste good (favour) after evil (poverty and harm) has touched him, he is sure to say: “Ills have departed from me.” Surely, he is exultant, and boastful (ungrateful to Allâh). (10)
Except those who show patience and do righteous good deeds, those: theirs will be forgiveness and a great reward (Paradise). (11)
Short tafsir of these beautiful verses can be found here. Great reminder!