Former prime minister wins Somalia's presidential vote
A former prime minister who holds dual Somali-US citizenship has been declared Somalia's new president.
Mohamed Abdullahi Farmajo immediately took the oath of office as the long-chaotic country moved towards its first fully functioning central government in a quarter of a century.
Incumbent president Hassan Sheikh Mohamud conceded defeat after two rounds of voting, and Mr Farmajo was declared the new leader.
"History was made, we have taken this path to democracy, and now I want to congratulate Mohamed Abdullahi Farmajo," Mr Mohamud said.
The election took place under heavy security amid threats from extremist group al-Shabab, with a security lockdown closing the capital's international airport and clearing major streets.
Mr Mohamud held a slight lead over Mr Farmajo, 88 votes to 72, after the first round of 21 candidates, but Mr Farmajo held a clear lead after the second round among the three candidates remaining.
Celebratory gunfire rang out in the capital, Mogadishu, from soldiers supporting Mr Farmajo, police said.
"This victory represents the interest of the Somali people. This victory belongs to Somali people, and this is the beginning of the era of the unity, the democracy of Somalia and the beginning of the fight against corruption," Mr Farmajo said after taking the oath.
Years of warlord-led conflict and al-Shabab attacks, along with famine, have left the Horn of Africa country of about 12 million people largely shattered.
Members of the upper and lower houses of the legislature dropped their ballots into clear boxes at the heavily guarded election venue, a former air force base in Mogadishu.
Fears of al-Shabab attacks limited the election to politicians instead of the population at large.
Across Mogadishu, Somalis gathered around TV screens at cafes and homes, eagerly watching the vote.
"I hope they will not choose bribes over the interest of the people," said Ahmed Hassan, a 26-year-old university student, who sat with dozens of men in front of a large television screen.
"We need an honest leader who can help us move forward."
Somalia's instability landed it among the seven Muslim-majority countries affected by US President Donald Trump's executive order on immigration, even though its government has been an increasingly important partner for the US military on counterterrorism efforts, including drone strikes against al-Shabab leaders.
In a sign of the dangers that remain in Mogadishu, two mortar rounds fired by suspected extremists late on Tuesday hit near the election venue.
There were no public statements by al-Shabab on Wednesday.
While the international community has pushed Somalia to hold this election as a symbol of strength, including the US pouring in hundreds of millions of dollars in recent years for political and economic recovery, the vote had been marred by reports of widespread corruption.
The legislators voting - 275 members of the lower legislative house and 54 senators - were selected by the country's powerful, intricate network of clans.
Weeks ago, a joint statement by the United Nations, the US, European Union and others warned of "egregious cases of abuse of the electoral process".
Examples included violence, intimidation and men taking seats that had been reserved for female candidates, the joint statement said.
With reports of votes being sold for up to 30,000 dollars apiece, "this is probably the most expensive election, per vote, in history", the Mogadishu-based anti-corruption group Marqaati said in a report.