The following ayaat from the Qur'an will show how lessons are truly learnt from the examples provided and how they are relevant to the people of their time thus refuting the arguments put forth by non-muslim academics who critique the examples portrayed in the Qur'an.
Thenceforth were your hearts hardenend: They became like a rock and Even worse in hardness, for among rocks there are some from which rivers gush forth; others there are which when split asunder send forth water; and others which sink for fear of Allah, and Allah is not unmindful of what you do.
The ayat above is in reference to the 3 kinds of hearts in which an example of the rock is given. The 3 kinds of rock are as follows:
1) The rock that bursts open and water gushes out of it
2) The rock that cracks open and a small amounts of water seeps out of the crack
3) The rock that falls from the fear of Allah
If this example of the rock is in reference to the heart, then the heart which falls from the fear of Allah (the 3rd rock) is like being in the fold of Islam. The heart which cracks open (the 2nd rock) and the little water comes out is when a person is in the state of Imaan. The heart which bursts open (the 1st rock) and water gushes out is when one is in a state of Ihsaan.
To further understand this, let's take the example of Umar ibn al Khattab's conversion to Islam. It wasn't until the 6th year after the Prophet pbuh's first revelation that Umar came to Islam. So at first his heart was hardened like the rock. It only cracked open a little when he went out with intent to kill the Prophet pbuh; he found the Prophet pbuh by the Ka'bah praying and the words of the Qur'an moved him that he changed his mind. It was later on when he found out his sister had converted to Islam that he returned home and once he heard the message of the Qur'an that his heart [the rock] cracked open and the faith poured out. Faith inside the heart is like water in the rock.
Whilst this example above portrayed an analogy of the states of our hearts, the actual example Allah chose about the rock and comparing it to the varying states of the heart was for a specific reason and a specific audience. This particular verse is taken from Surah al-Baqarah in which Allah addresses as we know Bani Israeel. This example was thus given to Bani Israeel. Why? Because they already know the example of when water gushes out of the rock! [When Musa alayhi-salaam hit his stick on the rock and the 12 springs gushed forth - Quran 26:63]. Therefore, Allah swt used the example they [Bani Israeel] were already aware of! SubhanAllah! Who better to give an example to His creation than the Creator Himself!
[This post was a write up of my notes from Nouman Ali Khan's Divine Speech Seminar in London Dec 2011]