Why Does Peanut Fruit Grow in the Earth?

Many plants bear fruit just where flowers have bloomed. As for the peanut plant you can see its vines crowded with little yellow flowers, but you can never find any fruit on them. This is because it bears its fruit in the earth. When the vines grow little flowers bloom on them and each one has a purple stem linked to the ovary. The stems grow fast and push the ovaries into the earth when they touch the ground. The ovaries will turn into peanut fruit which will be ripe after 40 days in the earth.