The Hebrew people with their 40 years in the Sinai came to mind, of course. They were tempted. Their response was to grumble and complain which led to them succumbing to the temptation. Grumbling and complaining typified that people's time in the desert.
David, however, during his time in the desert, praised God and used that praise to overcome the temptation to question God's presence in his life. Praise typified David as much as grumbling and complaining typified the Hebrew people in the desert.
Jesus spent time in the desert also. He too was tempted. He overcame Satan by citing Scripture. The Word of God quoted the word of God.
From these examples, how do we best overcome temptation? Grumbling and complaining don't work. Let's praise God and learn the Scriptures. These are two proven methods for people who want to be overcomers and progress in the spiritual life.