As stated very well above, the characters in Agatha Christie's book die according to the way the characters die in the song "Ten Little Indians." To provide a broader context, the characters in the mystery have been chosen and lured to an uninhabited island by "U.N. Owen" (his name means "unknown"). They cannot escape to shore because of bad weather and the distance from the mainland. Two of the victims are servants who have been recently hired. They have all been brought to the island because they committed crimes which, whether legal or not, were immoral and led to another person's wrongful death.
For example, Emily Brent, a religious hypocrite, fired a pregnant servant, Beatrice Taylor, for immorality. As a result, Beatrice drowned herself. What Brent did was not technically illegal, but it was cruel and hard-hearted. In another example, the butler and housekeeper, Mr. and Mrs. Roger, withheld medicine from an elderly woman once in their care, so that she would die. They then inherited money she left them in her will. Dr. Armstrong operated on a woman while he was drunk, killing her through his irresponsible behavior.
In other words, these are all people who, in the eyes of the murderer dispensing justice, deserve to die.