Corn, beans, avocado, peanuts, casava, yams/sweet potatoes...these are all major parts of African diet, at least in Cameroon, where I live. People don't seem to eat much else sometimes! Yet all of these are New World foods. What plants did people in Africa eat before Columbus?
To start off, I want to clear something up. In North America at least, the terms yam and sweet potato are often used interchangeably. However, botanically speaking, true Yams are numerous species all in the family Diosocorea while sweet potatoes are in the family Convulvaceae.
All this means to say that while sweet potatoes were originally from the Americas, specific species of yams were found throughout Eurasia and Africa prior to the Columbian Exchange. Indeed, White Yams and Yellow Yams were staple crops of Bantu-speaking farmers.
For your broader question....well, it is a big question, potentially covering the eating habits of a continent. I'll try and give a broad overview, but it won't be comprehensive for everywhere.
Cereals in the book African Archaeology; Foods, Metals, Towns Jack Harlan lists several cereal crops that were domesticated in tropical Africa. He mentions the following:
Root crops
I already mentioned the presence of white and yellow yams as a staple crop. In addition, Taro (also called Cocoyam) was and is an important root crop. According to Bassey Andah in African Archaeology; Foods, Metals, Towns Taro was historically a dominant crop in the Calabar/Cross river region (at least in the 20th century). While to the west in the Niger river delta region, farming relied on mixed crops of yams, taro and cassava (a new world crop).
Aside from native yams, there was also the introduction of the water yam (purple yam) from Southeast Asia to the East African coast some time before the 8th century.
Bananas/Plantains
Banana species were likely originally domesticated in Melanesia Southeast Asia. The most common theory for how the various Banana species reached Africa is via Austronesian contact with East African coast circa 500 BC. Edit, more recent scholarship has thrown this theory into doubt, and there does not seem to be a clear answer for what route brought bananas to Africa.
However, curiously the earliest evidence for banana cultivation in Africa comes from banana phytoliths (essentially a plant fossil) found northeast of Yaounde dated to 2500 years before present. Though, there has been some back and forth as to the validity of that dating.
In any case, banana cultivation was tremendously important as a staple crop among many societies in the Congo rainforest (where it was a more suitable staple crop than Yam) and in the Great Lakes region. In How Societies are Formed, Jan Vansina suggests that introduction of plantain and water yams to northern Angola circa the 10th century AD supplemented diets based on staple cereal crops, and thus supported population growth.
Legumes, melons, etc.
You are right that peanuts are a new world introduction. However, West Africa has a native species of groundnut legume commonly called the Bambara nut which grows in a similar fashion to peanuts, and have historically been grown as a food source.
Ditto, cowpeas (also known as Black-eyed peas) are a legume native to West Africa, and used as a food source.
Aside from legumes, African farmers also cultivated various types of melons, including the watermelon.
As you say, the Columbian exchange had a tremendous impact on food production on the continent. The introduction of new food crops like casava, maize and peanuts allowed African societies to diversify their food sources and hedge against drought or inclement weather. Just like Jan Vansina's example of new crops leading to food surpluses and population growth in Angola after the 10th century, there was a similar impact for these new world crops.
Further reading
African Archaeology; Foods, Metals, Towns edited by Thurstan Shaw, Paul Sinclair, Bassey Andah and Alex Okpoko.
The Oxford Handbook of African Archaeology by Peter Mitchell and Paul Lane
How Societies are Formed by Jan Vansina
Nachitutis Gift by David M Gordon
A Green Place, A Good Place By David Lee Schoenbrun
I had started a (very incomplete) answer to this question myself last evening, but looks like /u/Commustar beat me to it! They got all of the most important African crops down. I'd like to add a bit of additional information on other prominent food sources,
Ensete
Also called "Abyssinian Bananas" or "False Bananas" in English, biologically speaking these are about as close to bananas as humans are to gorillas, so pretty similar but hardly identical. Much less widespread than true Bananas as their growing conditions are much more specific, and the plants are less adaptable. That said, they still became one of the main staple crops of what is now the SNNPR region of southwestern Ethiopia, and to a lesser extent Oromia and portions of modern Kenya and South Sudan.
Asian Rice
Not a typo! By the time Columbus sailed to the Caribbean, Asian Rice had become more common in Africa than Africa rice--at least in the regions adjacent to the Indian Ocean, as well as the Arabized regions of Northeastern Africa. Asian Rice is better suited to food production, with yields averaging 20% higher, such that when it was introduced to East Africa around 1000 AD it began to spread fairly quickly. However, it is a much more labor-intensive crop, which made it less viable than African Rice for early European (and enslaved African) colonists of the New World.
Foxtail Millet
With a lower yield than Pearl and Finger millets, it is no surprise that Foxtail millet was never as common as the other millets. However, it grows well in arid regions, making it a valuable crop for African farmers living on the semi-barren edge of arable land.
African Eggplant
African Eggplant, which is very closely related to but somewhat smaller than the much more famous Indian Eggplant, used to be widely grown in West Africa. Many eggplant-based dishes of the region today originally used African Eggplant, switching over to Indian Eggplant when the later became more popular as a result of global trade in the past few centuries.
Moringa (Cabbage-Tree)
Biologically a very distant relative to cabbages, this tree is native to the highlands of Eastern Africa and is capable of growing in semi-arid environments with poor soil quality. While the trees themselves look nothing like cabbage, their leaves have similar taste and nutritional value. Much like Ensete, their potential to become popular outside of Africa is neutered by its picky growing conditions and slow growth cycle, which have led to Cabbage-Trees becoming endangered in recent centuries due to increased deforestation and climate change.
Coconuts
While most commercially sold Coconuts in Africa are primarily descended from coconuts grown in India (or from crosses between Indian and West Pacific varieties), wild coconuts can be found growing in Tropical regions worldwide. While never domesticated in Africa, these were almost certainly foraged by nomadic and agricultural societies alike prior to the Columbian exchange.
Fruits!
Most fruits sold in Africa today originate from The Middle East and Southeast Asia--just as most other places worldwide. But especially before global trade spread new fruits to Africa, a wide variety of indigenous fruits were grown. By far the most famous are Watermelons (from the Horn of Africa) and Honeydew (from Northwestern Africa), and these are the only two widely grown today. But Baobab, Dika, Carob, and Safou, were all widely consumed at various points and locations in African history.
Even the Osage Orange, which was neither grown by the Osage (an indigenous people from the modern United States), or has any similarities to Oranges (it's more closely related to Mulberries and Figs), was grown for its edible seeds, despite the fruit itself being universally regarded as very tough, woody, and gross.
I'd just like to mention that the three-volume series, "Lost Crops Of Africa," covering vegetables, fruits, and grains, native to Africa, is an excellent read, and talks about many crops that are little known in the west.
Hey all,
If you frequent the sub, you know the drill. If you're here from /r/all, or browse only occasionally, please be aware we have strict rules here intended to enforce the very high bar we expect from comments, so before posting, please read our rules. We remove comments which don't comply, and consider everyone forewarned. If you have feedback or commentary about how things are run here, please don't post it in this thread. We'll just remove it. We love to hear thoughtful, constructive feedback via modmail however.
It can take time for an answer to show up, so we thank you for your patience. If you want to be reminded to come check back later, or simply find other great content to read while you wait, this thread provides a guide to a number of ways to do so, including the RemindMeBot- Click Here to Subscribe - or our Twitter.
Again though, please remember the rules, and keep them in mind while you browse. If you don't like how this subreddit is run, keep in mind that this method has seen us continue to succeed and grow for years, and isn't going to change, so at least try and make your complaint original. /r/AskHistory exists, so complaining about the rules to us is like going into a Ghanaian restaurant to complain they don't sell Ethiopian food, even though Queen of Sheba Restaurant is next door.