Not all cases of survival of the fittest are genetically simple. Two ways in which alleles can convey a variable degree of fitness are through heterozygote advantage and balanced polymorphism.
Sickle-cell anemia is a disease in which the red blood cells have a defective kind of hemoglobin, the molecule that carries oxygen. This defective hemoglobin is the result of one particular allele of a gene coding for a part of the hemoglobin molecule. One would expect that an allele that caused such a disease would have a very low fitness and would be acted on by natural selection until its frequency in the population was practically zero. However, the allele for sickle-cell anemia remains in the population, especially among groups of people who live in areas affected by malaria. This is because the anemia-causing allele also conveys a protection against malaria. The maintenance of this allele in the population is an example of heterozygote advantage. A person who is homozygous for this allele will have severe sickle-cell anemia and will be selected against. However, in areas were malaria is prevalent, people who are heterozygous for the allele (have one sickle-cell anemia allele and one healthy allele) are more fit than those lacking it because they are protected from malaria and still have one functional allele to produce the appropriate kind of hemoglobin to prevent severe sickle cell anemia. Because heterozygotes have an increased fitness, the allele is maintained in the population.
A balanced polymorphism occurs when two phenotypes of a given trait occur with equal frequency in a population over many generations. An example of balanced polymorphism is seen in the scale-eating fish Perissodus microlepis. These fish attack another species of fish by sneaking up behind them and eating scales off their flanks. To help them do this, the scale-eaters have mouths that open to one side. Populations of Perissodus have equal numbers of left- and right-mouthed fish. This is because prey species have adapted to guard themselves against attacks from the scale-eaters. If all Perissodus had mouths that opened to the same side, they would all attack their prey on the same flank, and the prey species would adapt to guard that side more carefully, making it harder for Perissodus to attack. With a balanced population, prey species must split their guarding attention between both flanks, making it easier for either left- or right mouthed Perissodus to attack.