Whether an animal will become a male, a female, or a hermaphrodite is determined very early in development. Scientists have worked for hundreds of years to understand the sex-determination system.
The first major breakthrough in understanding sex determination was the discovery of sex chromosomes in the early 1900s. From meticulous analyses of male and female insect chromosomes, scientists discovered that, although most chromosomes were present in equal numbers in both males and females, there were one or two additional chromosomes that were unequally represented in the two sexes. Analyses of additional species over the years has revealed that chromosomal differences are primarily responsible for sex determination in most animals.
The XY sex-determination system is the sex-determination system found in humans, most other mammals, some insects (Drosophila), some snakes, and some plants (Ginkgo). In this system, the sex of an individual is determined by a pair of sex chromosomes (gonosomes). Females typically have two of the same kind of sex chromosome (XX), and are called the homogametic sex. Males typically have two distinct sex chromosomes (XY), and are called the heterogametic sex. Exceptions to these generalisations happen in the cases of XX males or XY females, or other syndromes. The XY system contrasts in several ways with the ZW sex-determination system found in birds, some insects, many reptiles, and various other animals, in which the heterogametic sex is female. It had been thought for several decades that in all snakes gender was determined by the ZW system, but there had been observations of unexpected effects in the genetics of species in the families Boidae and Pythonidae; for example, parthenogenic reproduction produced only females rather than males, which is the opposite of what is to be expected in the ZW system. In the early years of the 21st century such observations prompted research that demonstrated that all pythons and boas so far investigated definitely have the XY system of sex determination. Subscribe on YouTube