Abu Hurairah (May Allah be pleased with him) reported:
The Prophet (ﷺ) said, "A man bought a piece of land from another man, and the buyer found a jar filled with gold in the land. The buyer said to the seller: 'Take your gold, as I bought only the land from you and not the gold.' The owner of the land said: 'I sold you the land with everything in it.' So both of them took their case before a third man who asked: 'Have you any children?' One of them said: 'I have a boy.' The other said, 'I have a girl.' The man said: 'Marry the girl to the boy and spend the money on them; and whatever remains give it in charity."'[Al-Bukhari and Muslim].
App reference: Book 19, Hadith 19
Arabic/English book reference: Book 19, Hadith 1826