'Abdur-Rahman bin Abi-Bakrah narrated from his father that a man said: "O Messenger of Allah! Which of the people is the best?" He said: "He whose life is long and his deeds are good." He said: "Then which of the people is the worst?" He said: "He whose life is long and his deeds are bad."
Source: sunnah.com
Other translations
Arabic
حَدَّثَنَا أَبُو حَفْصٍ، عَمْرُو بْنُ عَلِيٍّ حَدَّثَنَا خَالِدُ بْنُ الْحَارِثِ، حَدَّثَنَا شُعْبَةُ، عَنْ عَلِيِّ بْنِ زَيْدٍ، عَنْ عَبْدِ الرَّحْمَنِ بْنِ أَبِي بَكْرَةَ، عَنْ أَبِيهِ، أَنَّ رَجُلاً، قَالَ يَا رَسُولَ اللَّهِ أَىُّ النَّاسِ خَيْرٌ قَالَ " مَنْ طَالَ عُمُرُهُ وَحَسُنَ عَمَلُهُ " . قَالَ فَأَىُّ النَّاسِ شَرٌّ قَالَ " مَنْ طَالَ عُمُرُهُ وَسَاءَ عَمَلُهُ " . قَالَ أَبُو عِيسَى هَذَا حَدِيثٌ حَسَنٌ صَحِيحٌ .
sunnah.com