Hermaphroditic nematodes can self-fertilize; the offspring
are mostly hermaphrodites; less than 1% are males.
But when hermaphrodites are mated with males,
the offspring are about 1:1 hermaphrodites:male.
Sex is determined by the ratio of X chromosomes to the number of sets of autosomes:
hermaphrodites have 2 X chromosomes and 2 copies of each autosome,
while males have only 1 X chromosome.