“Your sense of taste and smell is developed in utero,” says Julie Mennella, of the Monell Chemical Senses Center, in Philadelphia. “What the mother eats, a lot of [the flavors]—the garlic, vanilla, carrot, anise, a whole host of different flavors—are transmitted through the bloodstream and flavor amniotic fluid … If a baby has experienced a flavor in utero or in breastmilk, they prefer it more.” Fetuses can get a lot of exposure to whatever flavors their mother recently tasted—near the end of a pregnancy, they can swallow almost a liter of amniotic fluid a day.

These early flavor encounters can shape palates after birth. One study in which Mennella and other researchers randomly assigned some of their subjects to drink carrot juice daily in the last few months of pregnancy or after birth, during lactation, found that those women’s children had a stronger preference in infancy for the flavor of carrots than the babies of women who were instructed to avoid carrots and drink water. Another study that had pregnant women eat garlic found a similar effect that persisted into the children’s adolescence.