Verily, a man would perform the deeds of the people of Paradise for a long time, then his deeds would be concluded with the deeds of the people of Hell. And verily, a man would perform the deeds of the people of Hell for a long time, and then his deeds would be concluded with the deeds of the people of Paradise. (Using translation from Muslim 2651)
عَنِ النَّبِيِّ ﷺ قَالَ إِنَّ الرَّجُلَ لَيَعْمَلُ الزَّمَانَ الطَّوِيلَ بِأَعْمَالِ أَهْلِ الْجَنَّةِ ثُمَّ يَخْتِمُ اللهُ لَهُ عَمَلَهُ بِأَعْمَالِ أَهْلِ النَّارِ فَيَجْعَلُهُ مِنْ أَهْلِ النَّارِ وَإِنَّ الرَّجُلَ لَيَعْمَلُ الزَّمَانَ الطَّوِيلَ بِأَعْمَالِ أَهْلِ النَّارِ ثُمَّ يَخْتِمُ اللهُ لَهُ عَمَلَهُ بِأَعْمَالِ أَهْلِ الْجَنَّةِ فَيَجْعَلُهُ مِنْ أَهْلِ الْجَنَّةِ فَيُدْخِلُهُ الْجَنَّةَ