Gene duplication plays a fundamental role in evolution by providing the genetic material from which novel functions can arise. Newly duplicated genes can be maintained by subfunctionalization (the duplicated genes perform different aspects of the original gene's function) and/or neofunctionalization (one of the genes acquires a novel function). PLENA in Antirrhinum and AGAMOUS in Arabidopsis are the canonical C-function genes that are essential for the specification of reproductive organs. These functionally equivalent genes encode closely related homeotic MADS-box transcription factors. Using genome synteny, we confirm phylogenetic analyses showing that PLENA and AGAMOUS are nonorthologous genes derived from a duplication in a common ancestor. Their respective orthologs, SHATTERPROOF in Arabidopsis and FARINELLI in Antirrhinum, have undergone independent subfunctionalization via changes in regulation and protein function. Surprisingly, the functional divergence between PLENA and FARINELLI, is morphologically manifest in both transgenic Antirrhinum and Arabidopsis. This provides a clear illustration of a random evolutionary trajectory for gene functions after a duplication event. Different members of a duplicated gene pair have retained the primary homeotic functions in different lineages, illustrating the role of chance in evolution. The differential ability of the Antirrhinum genes to promote male or female development provides a striking example of subfunctionalization at the protein level.