Three things if found in a person then they would be beneficial to themselves and to the larger community, and they are:
1. They believe in the Creator
2. They believe in the Hereafter
3. They do good deeds
Lack in any of the above, puts the person at a great risk to themselves and to others.
I hope you will be able to read it in the following verse:
“Indeed, those who believed and those who were Jews or Christians or Sabeans – those [among them] who believed in Allah and the Last Day and did righteousness – will have their reward with their Lord, and no fear will there be concerning them, nor will they grieve.”
Quran 2:62