It is narrated from Sayyiduna Ibn Mas'ud (may Allah be pleased with him) that once a man kissed a strange woman, then, feeling remorse, he came to the Prophet (peace and blessings be upon him) to ask about its expiation. Upon this, Allah revealed this verse: «﴿وَأَقِمِالصَّلَاةَطَرَفَيِالنَّهَارِوَزُلَفًامِنَاللَّيْلِإِنَّالْحَسَنَاتِيُذْهِبْنَالسَّيِّئَاتِ﴾»[هود : 114] "Establish prayer at the two ends of the day and at some hours of the night; indeed, good deeds erase bad deeds." He asked: O Messenger of Allah (peace and blessings be upon him)! Is this command specific to me? He replied: "No, rather this command is for every person of my Ummah who commits such an act."
Hadith Referenceمسند احمد / مسند المكثرين من الصحابة / 4094