The riddle
What Did the Limestone Say to the Geologist?
AnswerDon't take me for granite
An idiom with a rock in it
Take for granted is the phrase for not appreciating someone. The riddle turns granted into granite. The limestone is afraid of being mistaken for granite, and a geologist is the person who could make that mistake.
The two words are near, but not equal: granted has a t before the last syllable and ends in d, and granite has no t there and ends in t. The first syllable and the stress are the same, which is enough for the pun to land.