ACCRA, Ghana (CNN)  -- President Obama reached out to Africa on Saturday with a wide-ranging address praising the continent's steady achievements, but he called its persistent violent conflicts "a millstone around Africa's neck."



President Obama speaks before Ghana's Parliament on Saturday.



"Despite the progress that has been made -- and there has been considerable progress in parts of Africa -- we also know that much of that promise has yet to be fulfilled," Obama said in a speech to the parliament of Ghana, a western African nation seen as a model of democracy and growth for the rest of the continent.



Ghana was the first sub-Saharan nation to gain independence, in 1957, and Obama continually cited the nation during his speech for its stability, political strides and painstaking economic progress. Its stability stands in contrast to other hot spots on the continent, such as Zimbabwe, where the society is in economic and political turmoil; Sudan, where fighting rages in the Darfur region; and Somalia, where a shaky transitional government is now battling an Islamic insurgency.



Ghana, with a population of 24 million, was once a major slave trading center. Obama visited the Cape Coast Castle, a British outpost where slaves were held until shipped overseas, along with his daughters.  Watch Obama's remark after touring Cape Coast Castle »



"I think it was particularly important for Malia and Sasha, who are being raised in a very blessed way, that history can take some cruel turns," he said. "And hopefully, one of the things that was imparted to them during this trip is their sense of obligation to fight oppression and cruelty wherever it appears."



Obama, whose father was Kenyan, compared the history to that of the Holocaust, Nazi Germany's efforts to exterminate the Jews of Europe during World War II.



"It's one of those things that you don't forget about," he told CNN in an interview scheduled to air Monday on "Anderson Cooper 360."



"I think it's important that the way we think about it, the way it's taught, is not one in which there's simply a victim and a victimizer, and that's the end of the story," he said. "I think the way it has to be thought about, the reason it's relevant, is whether it's what's happening in Darfur or what's happening in the Congo or what's happening in too many places around the world, the capacity for cruelty still exists."  Watch how Ghana is celebrating the Obamas' visit »



But he told lawmakers that Ghana now shows "a face of Africa that is too often overlooked by a world that sees only tragedy or the need for charity." While the nation-building the country exemplifies may lack "drama of the 20th century's liberation struggles," he said "it will ultimately be more significant."



As he has in past remarks, including his Cairo address last month about U.S.-Muslim relations, Obama stressed the superiority of governments that "respect the will of their own people," saying they foster more prosperity and stability than governments that don't.  Watch Obama deliver speech to Ghanaian lawmakers »



"No business wants to invest in a place where the government skims 20 percent off the top, or the head of the Port Authority is corrupt," he said. "No person wants to live in a society where the rule of law gives way to the rule of brutality and bribery. That is not democracy, that is tyranny, even if occasionally you sprinkle an election in there."



Even Kenya, his father's homeland, continues to struggle with tribalism and corruption, he said. That eastern African nation "had a per-capita economy larger than South Korea's when I was born" and now, he says, it has been "badly outpaced."



But he said Kenya has restored stability after the violence that followed the disputed 2007 election. South Africa has had high voter turnout in recent elections, and Zimbabwe's Election Support Network has defended the right
What did Obama tell Ghana lawmakers? Which African  lawmakers did Obama tell needs, "opportunity for more people?
"Despite the progress that has been made -- and there has been considerable progress in parts of Africa -- we also know that much of that promise has yet to be fulfilled," Ghana's Parliament
question: What did Obama tell Ghana lawmakers?, answer: "Despite the progress that has been made -- and there has been considerable progress in parts of Africa -- we also know that much of that promise has yet to be fulfilled," | question: Which African  lawmakers did Obama tell needs, "opportunity for more people?, answer: Ghana's Parliament