In an electoral surprise, a man from New York recently became president. No, not that man, and not from that slice of New York—Mohamed Abdullahi “Farmajo” Mohamed, a long-time resident of a Buffalo suburb and the former prime minister of Somalia, was selected as the next president of the African nation of Somalia earlier this week.

According to Merrit Kennedy at NPR, Mohamed was the surprise winner against incumbent president Hassan Sheikh Mohamud in an election by the nation’s Parliament. Kennedy explains that over several months, 14,000 Somali elders elected 275 members of parliament and 54 senators. Those newly elected officials gathered in a fortified base in Mogadishu to vote for president. From a field of 20, the first vote reduced the pool of candidates to three, including Mohamed and Mohamud. In the second round of voting, Mohamed was declared the winner. Mohamud conceded to the new president.

The New York Times' East Africa bureau chief Jeffrey Gettleman quotes a Somalia analyst who explains what happened as follows: "The least corrupt and most-well-liked candidate won Somalia’s most corrupt and least democratic election."

Though Mohamed has spent the most of the last year campaigning in his native country, the 54-year-old spent the majority of his adult life in the United States. Jane Kwiatkowski Radlich at The Buffalo News reports that in the 1980s Mohamed worked for Somalia’s ministry of foreign affairs, moving to Washington in 1985 where he worked at the Somalia embassy for four years. After applying for asylum, he moved to Buffalo because of its large Somali population, Radlich reports. He eventually became a dual U.S./Somali citizen.

Mohamed has worked for the Buffalo Municipal Housing Authority, for Erie County’s division of Equal Opportunity Employment and was an employee of New York’s Department of Transportation. In 2010, he met with then-president of Somalia Sheikh Sharif Ahmed who was visiting New York. In November of that year Ahmed selected Mohamed to become Somalia’s prime minister. His time in office was brief, and political infighting led to his dismissal in June 2011. The rare politician who's enjoyed wide support in Somalia, his departure led to violent protests in which demonstrators demanded Mohamed’s reinstatement.

The Somali community in Buffalo have watched Mohamed's run for the presidency carefully. “Somalia is having a difficult time,” Bashir Hagi Abdi a Buffalo-based Somali tells Radlich. “There are three reasons: militant groups, instability of neighboring countries and political clans. I believe the new president will have to work very hard, and he will because he is a great leader. In the eight months that Mohamed was prime minister he pushed out militant groups and fought corruption.”

David Lawler at The Telegraph, reports that Mohamed is not alone in returning to his embattled nation. Most of the officials elected during the recent elections were dual-citizens who have lived outside Somalia during the country’s decades of political turmoil.

Nor is Mohamed the first dual U.S. citizen to be elected president of another country. Golda Meir, born in Ukraine, received U.S. citizenship when her father was naturalized. She became prime minister of Israeli in 1969.

While dual citizenship is accepted for politicians in Somalia, other African nations that have experienced similar diasporas are not quite as accepting. In Liberia, politicians and intellectuals have debated for years whether dual citizens should be allowed to hold power, especially after the 2006 election of Ellen Johnson-Sirleaf, the first democratically elected female president in Africa, who has dual Liberian/German citizenship.