Source for the "50" figure
How did they avoid civil wars? I see a recurring them of US/USSR playing different sides to build control via proxies. How were some countries able to avoid this deadly game?
I think we need to clarify our terms. What do we mean by Civil War? does a coup d'etat count? or are we only talking about sustained fighting between military/paramilitary groups?
Because, there were many instances of coups deposing civilian leadership within the first decade of independence for many countries.
But, I tend to view a coup as not a civil war. I see a big distinction between the coups in Ghana in 1966, 1979 and 1982, versus something like the Congo Crisis or the Sudan Civil Wars.
So, if we are not considering coups to be civil wars, then 30 out of 55 African countries can be said never to have had a civil war. (though, many of those did have coups).
Also, how are we defining "soon after [independence]"? within 10 years? within 40 years?
There were some high-profile instances of civil wars that happened within a decade of independence. Instances like Nigeria's Biafra war, the Congo Crisis, the First Sudan Civil War, Angola civil war and Mozambique civil war.
On the other hand, there are other examples where a country enjoyed relative peace and stability for 25 or 30 or 35 or 50 years before experiencing a civil war. Somalia, Cote D'ivoire, Algeria and Sierra Leone are examples like this.
If we are taking a narrow definition of "soon after" to mean "within 10 years of independence" then I think it's maybe 8 or 10 out of those 50 countries you mention.
Of course, it gets into tricky judgement calls.
After World War 2, the Italian colony of Eritrea was made part of a federation with Ethiopia. Does the struggle from 1960-93 count as an Ethiopian civil war, or is it an Eritrean independence war?
For that matter, Ethiopia is usually regarded as having avoided colonialism. But, from 1977-1993 fought a protracted civil war.
Do we consider the period from 1964-79 as a post-UDI civil war (the "Rhodesian Bush War") or as a liberation war (Second Chimurenga) where authentic independence only happens in 1980?
Ditto, was Apartheid South Africa independent? was the armed struggle by umKhonto we Sizwe (armed wing of the ANC) and the Azanian Peoples Liberation Organization (armed wing of the Pan Africanist Congress) a civil war against the Apartheid state? or was it a liberation and majority rule struggle, and should we consider South African independence to start in 1994 rather than 1931?
Anyhow, I think I am getting into the weeds with that. My point is, I strongly disagree with your statement that "Almost all experienced civil wars soon after [independence]."
Many newly-independent countries faced political revolutions and coups, but armed civil conflict was the exception, not the norm.