KUALA LUMPUR, Malaysia — Mahathir Mohamad, who ruled Malaysia with an iron fist from 1981 to 2003, was sworn in for a second stint on Thursday to become the world's oldest elected leader.
The 92-year-old's alliance of four parties unexpectedly trounced the Barisan Nasional (BN) coalition of Prime Minister Najib Razak, who was once Mahathir's protege but became his most bitter rival.
The BN coalition had ruled the Southeast Asian nation for six decades since independence from Britain.
Mahathir was officially sworn in after an audience with the country's king.
Earlier on Thursday, Najib appeared to raise doubts that Mahathir would immediately take office because no single party had won a simple majority of seats in the 222-member parliament, and it would be up to the monarch to decide.
Official results showed that Mahathir's coalition won 113 seats, one more than the number required to rule. But it has not been formally registered as an alliance.
Mahathir said he had been assured of support from a raft of parties that would give his government 135 members of parliament.
Few had expected Mahathir to prevail against a coalition that has long relied on the support of the country's ethnic-Malay majority.
However, he joined hands with jailed political leader Anwar Ibrahim, his one-time deputy he developed a rift with in 1998, and together their alliance exploited public disenchantment over the cost of living and a multi-billion-dollar scandal that has dogged Najib since 2015.
"This election has proved to us that we moved beyond racial politics," said Khoo Ying Hooi, a professor of international and strategic studies at the University of Malaya. "It's really people power through the ballot."
Mahathir said that one of his first actions would be to seek a royal pardon for Anwar. Before the election, he had promised to step aside once Anwar was free and let him become prime minister.
His wife, Wan Azizah Wan Ismail, was sitting next to Mahathir at the news conference. Under an agreement with Mahathir, she is to be deputy prime minister.
Anwar was imprisoned, first by Mahathir on charges of corruption and sodomy. He was released in 2004 but jailed again by Najib in 2015.