Evolution of Separate Genders in Animals



Can anyone help me out with a query? I know that the swapping of
genetic material between organisms arose before the formation of
separate genders, but did separate genders come before hermaphrodites
or was it the other way round? Any website links that would help here
would be greatly appreciated.

.