The belief does not come from the Quran. While the Quran describes the beautiful companions of paradise (often called Hur or Houri), it never specifies a number . The specific number "72" appears in a hadith recorded by Imam al-Tirmidhi, a highly respected collector of hadith. This particular narration states that a martyr (shahid) is promised six special rewards from God, one of which is marriage to 72 maidens of paradise (al-hoor al-‘iyn) .
Don't know where God is but the Devil is in the details
佢條嘢仲金槍不倒添
It was narrated from Abu Umamah that the Messenger of Allah (ﷺ) said:
“There is no one whom Allah will admit to Paradise but Allah will marry him to seventy-two wives, two from houris and seventy from his inheritance from the people of Hell, all of whom will have desirable front passages and he will have a male member that never becomes flaccid (i.e., soft and limp).’” https://sunnah.com/ibnmajah:4337
Don't know where God is but the Devil is in the details